RE: [PHP] PHP 4.0.6 and APXS2

From: Date: Wed, 27 Jun 2001 15:05:22 +0000
Subject: RE: [PHP] PHP 4.0.6 and APXS2
Groups: php.general 
Request: Send a blank email to php-general+get-55401@lists.php.net to get a copy of this message
Hello, I believe include problem is a small typo... the include path needs to be ./:/usr/local/lib/php There is a php function to change the working directory, I'm not remembering it off the top of my head, but you can do either: exec("cd $path && ls -d */*.jpg",$ls); or: exec("ls -d $path/*/*.jpg",$ls); --- Toolshed Computer Productions - Professional PHP Hosting Hosting - Dedicated Servers - Design - Programming http://www.toolshed51.com -----Original Message----- From: Gonyou, Austin [mailto:austin@coremetrics.com] Sent: Tuesday, June 26, 2001 12:59 PM To: php-general@lists.php.net Subject: [PHP] PHP 4.0.6 and APXS2 After getting apache 2 + 4.0.6 built and installed, I can finally use PHP and all is well..except... When accessing a script which uses an exec() statment like the following: ----snip----- exec("ls -d */*.jpg",$ls); ----snip----- When the LS is performed, it is not performed in the directory where the PHP resides, but rather in /tmp. What's going on here. Also, I have the following errors: -----snip----- Warning: Failed opening 'header.inc.php' for inclusion (include_path='.:/usr/local/lib/php') in /tmp/really_silly on line 3 Warning: Failed opening 'footer.inc.php' for inclusion (include_path='.:/usr/local/lib/php') in /tmp/really_silly on line 26 -----snip----- The includes are relative to the path that the PHP script is in. It should just work, but instead it does what you see above. I didn't see this behaviour with Apache 1.3.x but it could be my Output/Input Filter definitions too. Any feedback is appreciated. -- Austin Gonyou Systems Architect, CCNA Coremetrics, Inc. Phone: 512-796-9023 email: austin@coremetrics.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net For additional commands, e-mail: php-general-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.general (#55401) next »