Subject: pkg/36916: php5 include od type ../foo.php fails
To: None <email@example.com, firstname.lastname@example.org,>
From: None <email@example.com>
Date: 09/05/2007 13:00:01
>Synopsis: php5 include od type ../foo.php fails
>Arrival-Date: Wed Sep 05 13:00:00 +0000 2007
>Originator: Tobias N. Sasse
>Release: 3.1 Stable
NetBSD gabriel 3.1 NetBSD 3.1 (GENERIC) #0: Tue Oct 31 04:27:07 UTC 2006 firstname.lastname@example.org:/home/builds/ab/netbsd-3-1-RELEASE/i386/200610302053Z-obj/home/builds/ab/netbsd-3-1-RELEASE/src/sys/arch/i386/compile/GENERIC i386
it's the second time that this error occurs. First time was after upgrading php5 to version 5.2.3, now the same with version 5.2.4.
First of all: All configuration of php is set to default values, and I've checked all file permissions etc twice.
The Problem: I installed lang/php5, www/ap-php by pkgsrc (make install). After restarting the apache, every include/require in ALL php scripts produces an error like this:
Warning: require(../includeme.php) [function.require]: failed to open stream: Permission denied in /var/www/subdir/foo.php on line X
Fatal error: require() [function.require]: Failed opening required '../includeme.php' (include_path='.:') in /var/www/subdir/foo.php on line X
So you can see that a script in a subdirectory can't include another script from the basedirectory.
Again: I did not change the default config.
Last time the error occured an update of php5 solved the problem... So I hope you will find the error soon and supply a patch!
If you want to see some output of phpinfo() go for:
Hopefully somebody can help!
With regards to your work and greetings from Germany,
cd /usr/pkgsrc/www/apache22 && make install
cd /usr/pkgsrc/lang/php5 && make install
cd /usr/pkgsrc/www/ap-php && make install
Try to include something from an upper directory.