If you want to access Drupal functions and sessions in your stand alone PHP scripts which is present any where in your project directory then how you will do this?
Let say you are going to create one websevices in drupal thats mean you have to create one PHP stand alone file then how you will access the Drupal functions?
First of all I am clearing this that this solution is for Drupal 7, not sure this will work in Drupal 6 or not, as I have not tested this in Drupal 6 environment.
Below are the code you have to write in you PHP stand alone file.
Now you can access any function of Drupal 7 in this stand alone PHP file