I have my local server set up as virtual host.

i am getting errors on my remote server
Warning: main() [function.main]: open_basedir restriction in effect. File(/WA_eCart_Definition_PHP.php) is not within the allowed path(s): (/var/www/vhosts/markwatsoncarvings.com/httpdocs:/tmp) in /var/www/vhosts/markwatsoncarvings.com/httpdocs/WA_eCart/markwatsonCart_PHP.php

both my local & remote php.ini has setting
;open_basedir =

phpinfo() on local server shows
Virtual Directory Support enabled
open_basedir no value no value

phpinfo() on remote server shows
Virtual Directory Support disabled
open_basedir var/www/vhosts/domain.com/httpdocs:/tmp no value

i have access to my remote server php.ini & httpd.conf files

Will enabling Virtual Directory Support on my remote server solve my errors? If so, where can I enable that?

thanks for your help,
Jim Balthrop

    The problem isn't a configuration issue, it has to do with your path. I highly doubt that this "WA_eCart_Definition_PHP.php" file exists in the root of your server's hard drive (which is where you're telling PHP to look by prefixing the path with a '/').

    Try prefixing the path with $_SERVER['DOCUMENT_ROOT'] instead of just '/'.

      Write a Reply...