Can't seem to find the difference between these. D6 is what I need to know, but would love to know how those looks into 7 and even 8.


$base_root is:

The root URL of the host, excluding the path.

e.g. http://localhost

$base_url is:

The base URL of the drupal installation.

again, e.g. http://localhost

The only situation I can think of where these would be different is if your Drupal installation is in a sub-folder of the web root. In that case $base_url would also contain the sub-folder in the path, e.g. http://localhost/drupal

The descriptions in the documentation are exactly the same for both across versions 6, 7 and 8.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.