I have apache2 setup on my local machine with virtualhosts.
In my hosts file, i have this:
'mysite' is a site, in which i have php scripts that use include('/path/to/whatever');
If i type 'mysite' in my browser's url, everything loads fine.
If however i type http://localhost/mysite,
i get errors such as: Warning: include(/media/Shared/sites/www/includes/functions.php
Notice in the errors, after 'www', it's missing 'mysite'. so my script thinks 'www' is the root, and not 'www/mysite'. This is a problem because same thing happens when i access the site via my external IP.
How can I fix this?