I have a script called 'sess-start.php' which is in the / include directory in my httpdocs directory.
My site continues this error: \
[Fri Mar 25, 14:52:24 2011] [error] [client 12.3.3.3] PHP Fatal error: require () [function.require]: Unsuccessful opening of '/includes/sess-start.php' (include_path = '.:') in /var/www/vhosts/site.com/httpdocs/page.php on line 4, referent: https://www.site.com/
although www.site.com/includes DOES exist. What gives!
Change 1
They include / require, which themselves may contain additional require or include requests. Relative paths DO NOT WORK, so please do not suggest such.
My .htaccess file already indicates that all include paths to the root directory of the site:
php_value include_path.:/Var/WWW/ virtual domains /site.com/httpdocs
Edit 2
Not all of my included or required scripts are in the same directory, so the suggestion to just put the / include directory in include_path will also be reset (and, in turn, also causes problems on the Windows machine).
Update
Perhaps some explanations on an example in real life can help solve the problem that our team is trying to solve:
On one page, the user can enter several parameters, the next page does the necessary calculations and, based on this, routes the client to several potential parameters, all of which lead to statements about something like a database record.
Then inside the db record (or some other action), if everything goes smoothly, the member may have chosen earlier to receive an email confirmation based on his actions. This request requires in the 2nd requirement (db insert), but is located in a different directory than the second, and thus causes a conflict, since the first file incorrectly refers to the link.
Hard coding the absolute path or even setting the appropriate path to include on the page is “ok”, but then it disables our ability of the command to link between files with Dreamweaver (or any other program that does the same) because it does not recognize "site root" when working in a test environment.