I have upgrade a script on one of my sites. One of the upgraded pages includes a header file. The header has another include. Ufter the upgrade I keep getting the following errors:
WARNING: main(): open_basedir restriction in effect. File(/home/domain.com/httpdocs/global/common.inc.php) is not within the allowed path(s): (/home/httpd/vhosts/domain.com/httpdocs:/tmp) in line 4 of file hdr.php WARNING: main(/home/domain.com/httpdocs/global/common.inc.php): failed to open stream: Operation not permitted in line 4 of file hdr.php WARNING: main(): Failed opening '/home/domain.com/httpdocs/global/common.inc.php' for inclusion (include_path='.:') in line 4 of file hdr.php
How can it be resolved?
did you read the manual entry on open_basedir?
Yes, just did. Lost even deeper... I assume I need to tweak php.ini
Either:
Disable open_basedir in php.ini (not necessarily something I'd recommend),
Change the open_basedir setting in php.ini to include the directory where your includes are, or
Move your includes to the open_basedir directory or one of its sub-directories.
My php.ini is set to:
include_path = ".:"
Where is that location?
If I wanted to change it to point to my actual include folder ((/home/domain.com/httpdocs/global/) would I make it:
include_path = "./home/domain.com/httpdocs/global/"
???
I'm blind! I was calling my include from my other site...