From:             daniel dot weck at free dot fr
Operating system: Windows XP
PHP version:      4.3.2
PHP Bug Type:     CGI related
Bug description:  Apache Location/ForceType works with 4.3.2 RC4, but not with 4.3.2 
FINAL !

IMPORTANT:
I have no problem with [PHP 4.3.2 RC4],
the bug only appears with [PHP 4.3.2 final]

I'm using the binary distribution of PHP for Windows,
along with Apache 2.0.46.
PHP is configured as CGI (not apache module) in httpd.conf.
So I use the CGI php.exe from the official PHP distribution.

I'm using the hilighting feature explained at:
http://fr.php.net/function.highlight-file
(Example 1. Creating a source highlighting URL)

Using PHP 4.3.2RC4, the example works fine,
but when I use the PHP 4.3.2 binaries (keeping the same php.ini, just
overriding the binaries), I get this in my browser:

No input file specified.


I traced getenv("PATH_TRANSLATED") and it seems to be the source of the
problem:


The following URL:
### http://localhost/source

generates an empty PATH_TRANSLATED with 4.3.2 RC4,
whereas 4.3.2 final generates this value:
[E:\www\source]
(which is the correct location on my file system)

The following URL:
### http://localhost/source/info.phps

generates this PATH_TRANSLATED with 4.3.2 RC4:
[E:/www/info.phps]
(which is the correct location on my file system)

whereas 4.3.2 final gives me the "No input file specified." message.

In fact,
### http://localhost/source/
(note the added '/' at the end)
returns PATH_TRANSLATED = [E:\www\source\]
(with the added '\' at the end)

and
### http://localhost/source/xxxxxxxx
with 'xxxxxxxx' that can be any phrase
returns "No input file specified."


According to these tests,
PHP 4.3.2FINAL differs from 4.3.2RC4
when it generates the PATH_TRANSLATED environement value.

I suspect the observed bug when using the basic hilighting script as
discribded in the manual
(http://fr.php.net/function.highlight-file)
is related to the PATH_TRANSLATED issue.
-- 
Edit bug report at http://bugs.php.net/?id=24000&edit=1
-- 
Try a CVS snapshot:         http://bugs.php.net/fix.php?id=24000&r=trysnapshot
Fixed in CVS:               http://bugs.php.net/fix.php?id=24000&r=fixedcvs
Fixed in release:           http://bugs.php.net/fix.php?id=24000&r=alreadyfixed
Need backtrace:             http://bugs.php.net/fix.php?id=24000&r=needtrace
Try newer version:          http://bugs.php.net/fix.php?id=24000&r=oldversion
Not developer issue:        http://bugs.php.net/fix.php?id=24000&r=support
Expected behavior:          http://bugs.php.net/fix.php?id=24000&r=notwrong
Not enough info:            http://bugs.php.net/fix.php?id=24000&r=notenoughinfo
Submitted twice:            http://bugs.php.net/fix.php?id=24000&r=submittedtwice
register_globals:           http://bugs.php.net/fix.php?id=24000&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=24000&r=php3
Daylight Savings:           http://bugs.php.net/fix.php?id=24000&r=dst
IIS Stability:              http://bugs.php.net/fix.php?id=24000&r=isapi
Install GNU Sed:            http://bugs.php.net/fix.php?id=24000&r=gnused

Reply via email to