* Thus wrote Ty Lamb ([EMAIL PROTECTED]):
> /index.php
> has
> include("/code/includes/page_header.php");
>
> /docs/aaryn/dmb/dave.php
> has
> include("/code/includes/page_header.php");
>
> Both are identical lines of code. Index.php works but dave.php returns the
> following:
>
> Warning: Failed opening '/code/includes/page_header.php' for inclusion
> (include_path='.;c:\php4\pear') in C:\x\x\x\x\x\aaryn\dmb\dave.php on line 4
>
> but if I change the code in dave.php to
> include '../../../code/includes/page_header.php';
ahh.. so your code/ is at your webroot (the same directory as
index.php?) I would have expected the /code to look at
c:\code\includes\page_header.php
But it seems that this isn't the case and I'm not familiar with how
windows handles the absolute path.
>
> It works.
>
> Why?
>
> Is there any way around this? Please tell me I'm doing something wrong and
> it's not supposed to work like this!!!
What I would suggest is to setup your include_path to look
something like:
include_path=".;c:\php4\pear;c:\path\to\code\includes"
Then your include will simply be
include("page_header.php");
Curt
--
"I used to think I was indecisive, but now I'm not so sure."
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php