Forum Moderators: coopster
/usr/top/public/the-script.php
This is the path that is shown if I print __FILE__. I have an include directory that lives here:
/usr/top/hidden
I do the following with ini_set:
ini_set("include_path", ".;/usr/top/hidden");
However if I try to include a file that resides in /usr/top/hidden using just the file name:
require_once("file-in-hidden-dir.php");
I get a fatal error saying the file could not be found, with the include path I set showing in the error dump as the correct include_path.
If I try opening up the file using an explicit full path declaration:
require_once("/usr/top/hidden/file-in-hidden-dir.php");
It opens without error. What could I be doing wrong to have this problem?
Thanks.
ini_set("include_path", ".:/usr/top/hidden");
You use a colon to separate the directories on a unix machine. You only use a semicolon for windows. See if changing that fixes anything.