Drupal – Get the absolute file path of your Drupal installation

You can get the absolute file path of your Drupal installation as follow.

echo realpath(".");
// output: /var/www/drupal-6.22

For more examples, please refer to Computer tips by Siripong – get absolute path in drupal modules

Done =)

One thought on “Drupal – Get the absolute file path of your Drupal installation”

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.