php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #4264 PHP4.0RC1 under Roxen 2.0 does not chdir() to the script directory
Submitted: 2000-04-27 12:39 UTC Modified: 2000-04-29 03:57 UTC
From: tstromberg at rtci dot com Assigned:
Status: Closed Package: Other
PHP Version: 4.0 Release Candidate 1 OS: FreeBSD 5.0-CURRENT
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: tstromberg at rtci dot com
New email:
PHP Version: OS:

 

 [2000-04-27 12:39 UTC] tstromberg at rtci dot com
When running PHP 4.0RC1 under Roxen 2.0.46, it never chdir's to the directory of the script, instead it stays in /usr/local/roxen.

This really screws up with relative paths for include() and fopen(). You could of course, chdir yourself in every document, but this is definitely not the behaviour I've seen in Apache. 

Script to reproduce problem. It should show the files /usr/local/roxen rather then the scripts directory:

$handle = opendir('.');
while ($file = readdir($handle)) {
  print ("$file\n");
}
closedir($handle);

configured with:
./configure  --with-roxen=/usr/local/roxen/server --with-mysql --with-xml

php.ini: 
only difference is include_path has "."


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-04-29 03:57 UTC] tstromberg at rtci dot com
By upgrading to the version of PHP in cvs, and defining VIRTUAL_DIR in php.h, it works great.

Thanks to David Hedbor for the heads up.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon May 06 08:01:33 2024 UTC