Re: PATH_TRANSLATED broken?
| From: | Uwe Schindler | Date: | Mon, 30 Jun 2003 11:30:08 +0000 |
| Subject: | Re: PATH_TRANSLATED broken? | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-3031@lists.php.net to get a copy of this message | ||
I think your problem with that comes from the fact, that in PHP4 the apache sapi module define this variable in the wrong way (mistake of original programmer). But a lot of scripts depend on that so we did not fix it in the PHP_4_3 branch. I think there is a former discussion about this in this mailing list! But PHP5 should follow the CGI spec: http://www.graphcomp.com/info/specs/cgi11.html
To get your version of the variable it would be better for the scripter to use $_SERVER['SCRIPT_FILENAME'].$_SERVER['PATH_INFO']
By the way in PHP4 all other SAPI modules do the translation in the right way.
At 11:57 30.06.2003 +0200, Derick Rethans wrote:
Hey, with this URL: http://dru-nl/b.php/1/r/2/1/1 I get back the following server variables (PHP 5.0.0b1, apache 1 module): 'REQUEST_URI' => '/b.php/1/r/2/1/1' 'SCRIPT_NAME' => '/b.php' 'PATH_INFO' => '/1/r/2/1/1' 'PATH_TRANSLATED' => '/home/httpd/html/dru/modules/user/1/r/2/1/1' 'PHP_SELF' => '/b.php/1/r/2/1/1' Shouldn't PATH_TRANSLATED be? 'PATH_TRANSLATED' => '/home/httpd/html/dru/modules/user/b.php/1/r/2/1/1' regards, Derick -- -------------------------------------------------------------------------Derick Rethans http://derickrethans.nl/ JDI Media Solutions http://www.jdimedia.nl/ International PHP Magazine http://www.php-mag.net/------------------------------------------------------------------------- -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php