php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #27954 PATH_INFO no longer works with IIS
Submitted: 2004-04-11 17:52 UTC Modified: 2004-04-13 19:22 UTC
From: demis at liquidbit dot com Assigned:
Status: Not a bug Package: CGI/CLI related
PHP Version: 4.3.5 OS: WINDOWS
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: demis at liquidbit dot com
New email:
PHP Version: OS:

 

 [2004-04-11 17:52 UTC] demis at liquidbit dot com
Description:
------------
I cannot get PATH_INFO working on Windows XP/IIS so I can show pages like this:

http://localhost/myapp/login.php/ADMIN

Changes to php.ini

doc_root = "C:\Inetpub\wwwroot"
cgi.force_redirect = 0
cgi.fix_pathinfo = 1

I have tried different values with these three config options and none work. I have already applied the configuration to get IIS to accept path info:
adsutil set w3svc/AllowPathInfoForScriptMappings True

The Error:
Warning: Unknown(c:\inetpub\wwwroot\ADMIN): failed to open stream: No such file or directory in Unknown on line 0

It appears php does not like to call my login script and prefers to instead run the imaginary script path_info "ADMIN" thats on my doc_root

NOTE: 
- Im using the windows binaries, compiling php with --enable-path-info-check may help - if its not already I hope this is the default with the windows binaries

- I have tried IIS with php CGI and isapi no joy.

- This setup works with apache and therefore solutions beginning with "Just use apache" are entertaining, they are not very helpful.


Expected result:
----------------
run my login.php script with the appropriate PATH_INFO variables fixed

Actual result:
--------------
The Error:
Warning: Unknown(c:\inetpub\wwwroot\ADMIN): failed to open stream: No such file or directory in Unknown on line 0


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-04-12 11:45 UTC] sniper@php.net
You say "no longer works", meaning it worked before? In what version? 

You said it works with Apache, so why do you think it's some bug in PHP but not some configuration issue within IIS??
(the error message looks like it is IIS which isn't passing the right information to PHP..)


 [2004-04-13 11:15 UTC] demis at liquidbit dot com
>>You say "no longer works", meaning it worked before? In what version?

Ok all was good with the last version of php I used 4.3.0 CGI

>>why do you think it's some bug in PHP

Because the error message is generated by php - which means IIS is doing its job of "finding" the script (login.php) and passing it to the php handler
 [2004-04-13 12:30 UTC] sniper@php.net
I was told IIS does not support this.

 [2004-04-13 19:22 UTC] demis at liquidbit dot com
IIS supports this fine you just have to add a config entry by running:

adsutil set w3svc/AllowPathInfoForScriptMappings True

as explained in: http://support.microsoft.com/default.aspx?scid=kb;en-us;q184320
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Oct 31 23:01:28 2024 UTC