Re: [PHP] Include fails when "./" is in front of file name
- From: stuttle@xxxxxxxxx (Stut)
- Date: Mon, 07 Apr 2008 16:24:18 +0100
Philip Thompson wrote:
On Apr 7, 2008, at 9:36 AM, Daniel Brown wrote:On Sun, Apr 6, 2008 at 5:17 PM, Noah Spitzer-Williams <noahsw@xxxxxxxxx> wrote:This works:
include("file.inc.php");
This doesn't:
include("./file.inc.php");
That's pretty vague, Noah. Is it unable to locate the file?
What's the error message you're receiving?
It's Windows. From experience, I know that it provides little to no error reporting in some instances. For example, if you're missing a semi-colon and you have error reporting turned on, all you get is a blank page - no other info. So, odds are is that he isn't receiving an error message.
I'm not sure where you got that from, error reporting does not differ between Windows and other platforms except where platform-specific differences exist in the implementation (of which there are few).
What you're experiencing is probably the effect of the display_errors configuration option. Look it up in the manual for details.
To the OP: Check that your include_path contains '.', if it doesn't add it and see if that fixes your problem.
-Stut
--
http://stut.net/
.
- Follow-Ups:
- Re: [PHP] Include fails when "./" is in front of file name
- From: "Daniel Brown"
- Re: [PHP] Include fails when "./" is in front of file name
- References:
- Include fails when "./" is in front of file name
- From: "Noah Spitzer-Williams"
- Re: [PHP] Include fails when "./" is in front of file name
- From: "Daniel Brown"
- Re: [PHP] Include fails when "./" is in front of file name
- From: Philip Thompson
- Include fails when "./" is in front of file name
- Prev by Date: Re: [PHP] included file var scope
- Next by Date: Re: [PHP] PHP ssh2 problem
- Previous by thread: Re: [PHP] Include fails when "./" is in front of file name
- Next by thread: Re: [PHP] Include fails when "./" is in front of file name
- Index(es):
Relevant Pages
|