|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #1546 Unable to pass path info while using php in cgi mode.
Submitted: 1999-06-16 01:16 UTC Modified: 2001-05-02 21:22 UTC
From: alec at brainpod dot com Assigned:
Status: Closed Package: *Web Server problem
PHP Version: 4.0 OS: Solaris
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
Solve the problem:
48 - 26 = ?
Subscribe to this entry?

 [1999-06-16 01:16 UTC] alec at brainpod dot com
I am unable to pass pathinfo to my script while using php in cgi mode.

The problem in particular (maybe you all know of a workaround) is I'm trying to create a download script.  While using PHP in cgi mode I can't get Netscape and IE to assign the download the proper name...

A possible solution could be a path_info translation something like:


Let me know what you think...

P.S.  The PHP base library is awesome and I wouldn't mind seeing future versions of PHP having the DB abstraction libraries that the PHP base library offers built in.

Alec Effrat
Brainpod Technical Consulting


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2001-02-10 13:26 UTC]
refiling as bug against 4.0.
 [2001-02-21 14:01 UTC]
user patch suggestion:

< #include <sys/types.h>
< #include <sys/stat.h>
< #if 0 
> #if 0
<         struct stat statbuf;
<         char *lastslashptr;
<                /*allow use of extended path in URL
<                (e.g:
<                 */
<                 lstat(env_path_translated,&statbuf);
<                 while(strlen(env_path_translated)!=0 &&
<                         && !S_ISLNK(statbuf.st_mode) &&
< 		  {
< 		     lastslashptr=strrchr(env_path_translated,'/');
< 		     if(lastslashptr)*lastslashptr='\0';
<  		     stat(env_path_translated,&statbuf);
<                    }

 [2001-05-02 21:22 UTC]
Please try latest CVS snapshot from
as this should be fixed. Reopen if this is not the case.


 [2002-07-15 22:24 UTC] phpbugs at mattholland dot com
This is *not* fixed, and shouldn't be closed. Having the exact same problem on Linux, using PHP 4.2.1 in CGI mode.
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Apr 24 15:01:30 2024 UTC