Inconsistent behaviour of the $base_path variable in themes

    When developing a Drupal site in a sub-folder, of for deployment on a different directory structure, it is always advisable not to user hard-coded root directory paths. It is best and strongly recommended to use the

    <?php print $base_path ?> variable to ensure that the URL with always use the correct root folder based on the $base_url setting in settings.php configuration file.

    I have noticed though that the $base_path setting is not working in Drupal 5.7x. If the site is located in a folder and not in the domain root, there risks being a root mismatch that will prevent your server-side applications/browser from finding images CSS references and other commands pointing to elements of the file-system. Searching on the Drupal website yields a bug path that is meant to fix this problem (http://drupal.org/node/229401). The intended path however generates an error

    Parse error: syntax error, unexpected T_IF in /home/xxxxxxxxxxx/public_html/_ngreens/includes/bootstrap.inc on line 266