Re: PHP includes without access to the default directory
| From: | Tom Rogers | Date: | Fri, 06 Dec 2002 06:36:25 +0000 |
| Subject: | Re: PHP includes without access to the default directory | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-127225@lists.php.net to get a copy of this message | ||
Hi,
Friday, December 6, 2002, 11:06:36 AM, you wrote:
G> I have a hosted account. As such, I am unable to use the default location
G> for files when used with the include command. So could somebody tell me how
G> I can either make it go to a different directory, or to link to something
G> (and how to add the variable as the filename)?
G> Thank you in advance.
If you still need access to the default include directory put this at the top of
each page:
ini_set
("include_path","/path/to/local/includes:"ini_get("include_path"));
Then no matter what directory you are in you can just include("filename");
--
regards,
Tom