#38476 [NEW]: PATH_INFO, ORIG_PATH_INFO, and PHP_SELF not set in Lighttpd1.4.11/PHP4.4.3

From: Date: Wed, 16 Aug 2006 20:09:39 +0000
Subject: #38476 [NEW]: PATH_INFO, ORIG_PATH_INFO, and PHP_SELF not set in Lighttpd1.4.11/PHP4.4.3
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-100873@lists.php.net to get a copy of this message
From:             fietka at rpi dot edu
Operating system: Debian Linux
PHP version:      4.4.3
PHP Bug Type:     CGI related
Bug description:  PATH_INFO, ORIG_PATH_INFO, and PHP_SELF not set in Lighttpd1.4.11/PHP4.4.3

Description:
------------
In the course of playing with my new Lighty server running on Debian, I
ran into a problem with the PHP_SELF, PATH_INFO, and ORIG_PATH_INFO
variables - specifically, Lighty doesn't provide them to my PHP install.

Even after applying all the fixes I could find:

Adding "broken-scriptfilename" => "enable" to my PHP config in
lighttpd.conf

Set cgi.fix_pathinfo = 1 in /etc/php4/cgi/php.ini

Compiled PHP4 with ./configure --enable-fastcgi --enable-ftp --with-mysql
--enable-force-redirect --enable-discard-path

Various combinations of these fixes didn't work either (PHP compiled with
and without each/both of the cgi-related switches). I found a workaround
for the KnowledgeTree? DMS: http://issues.ktdms.com/browse/KTS-1289 and a
Google Answers post I made generated some good kludges(though neither of
them work): http://google.com/answers/threadview?id=754764

This seems to be a fairly serious Lighty/PHP issue that affects a large
number of people and currently has no resolution. If anyone wants any
further information or wants to contribute ideas on how to fix this, feel
free to e-mail me. 

Reproduce code:
---------------
print $_SERVER["PATH_INFO"];
print $_SERVER["PHP_SELF"];
print $_SERVER["ORIG_PATH_INFO"];

Expected result:
----------------
null
null
null

Actual result:
--------------
Given site.com/folder/script.php,
/folder
/folder/script.php
/folder

-- 
Edit bug report at http://bugs.php.net/?id=38476&edit=1
-- 
Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=38476&r=trysnapshot44
Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=38476&r=trysnapshot52
Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=38476&r=trysnapshot60
Fixed in CVS:                 http://bugs.php.net/fix.php?id=38476&r=fixedcvs
Fixed in release:             http://bugs.php.net/fix.php?id=38476&r=alreadyfixed
Need backtrace:               http://bugs.php.net/fix.php?id=38476&r=needtrace
Need Reproduce Script:        http://bugs.php.net/fix.php?id=38476&r=needscript
Try newer version:            http://bugs.php.net/fix.php?id=38476&r=oldversion
Not developer issue:          http://bugs.php.net/fix.php?id=38476&r=support
Expected behavior:            http://bugs.php.net/fix.php?id=38476&r=notwrong
Not enough info:              http://bugs.php.net/fix.php?id=38476&r=notenoughinfo
Submitted twice:              http://bugs.php.net/fix.php?id=38476&r=submittedtwice
register_globals:             http://bugs.php.net/fix.php?id=38476&r=globals
PHP 3 support discontinued:   http://bugs.php.net/fix.php?id=38476&r=php3
Daylight Savings:             http://bugs.php.net/fix.php?id=38476&r=dst
IIS Stability:                http://bugs.php.net/fix.php?id=38476&r=isapi
Install GNU Sed:              http://bugs.php.net/fix.php?id=38476&r=gnused
Floating point limitations:   http://bugs.php.net/fix.php?id=38476&r=float
No Zend Extensions:           http://bugs.php.net/fix.php?id=38476&r=nozend
MySQL Configuration Error:    http://bugs.php.net/fix.php?id=38476&r=mysqlcfg


Thread (8 messages)

« previous php.bugs (#100873) next »