Re: Re: Really strange / TYPO

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Yes, permissions are fine :(

Ben Ramsey wrote:
> On 10/4/06 9:14 PM, Deckard wrote:
>> It's a typo.
>> The file is really config.inc.php everywhere
> 
> Check the file permissions. Does the Webserver have permission to read
> from the /var/www/html (it probably does, but it wouldn't hurt to
> check)? Does the Web server have permission to read
> /var/www/html/config.inc.php? Do you happen to have PHP running in
> safe_mode? If so, is the owner of /var/www/html/classes/dBInsert.php the
> same owner of /var/www/html/config.inc.php?
> 
> These are just the things I can think of off the top of my head that
> would block your script from being able to include a file one directory
> above it.
> 
>>
>> Ben Ramsey wrote:
>>> On 10/4/06 8:32 PM, Deckard wrote:
>>>> Hi,
>>>>
>>>> I have this line of code:
>>>> include_once('../config.inc.php');
>>>>
>>>> I'm 100% sure that the file config.inc.php is a directory up.
>>>>
>>>> config.inc.php is in /var/www/html
>>>> and the file that calls it is in
>>>> /var/www/html/classes
>>>>
>>>> nevertheless, i'm getting the error:
>>>> "Warning: main(../config.inc): failed to open stream: No such file or
>>>> directory in /var/www/html/classes/dBInsert.php on line 10
>>>>
>>>> Warning: main(): Failed opening '../config.inc' for inclusion
>>>> (include_path='.:/usr/share/pear') in
>>>> /var/www/html/classes/dBInsert.php
>>>> on line 10"
>>> The first thing that jumps out at me is that your error says it failed
>>> to open ../config.inc, but you say the file is named config.inc.php.
>>> Check your code to ensure that you have:
>>>
>>> include_once('../config.inc.php');
>>>
>>> and not:
>>>
>>> include_once('../config.inc');
>>>
>>> If config.inc.php is the correct file you want to include and you're
>>> trying to include config.inc, then it obviously can't find it because it
>>> doesn't exist. :-)
>>>
> 
> 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux