PHP 5 and IIS 5

  • Decipher
  • Newbie
  • Newbie
  • Decipher
  • Posts: 14

Post 3+ Months Ago

Ok guys, i know this topic has been beat to death but i keep going in circles. I want to start off by saying yeah yeah mysql this and apache that. I need to get my php working with IIS.

I'm running winxp pro, fully updated and all tht jaz. I recently installed php 5 with the windows installer and later added the the files that were apparantly left out or maybe they are no needed, from the .zip file. Also i have script access to my isr_computername account and all that, i may have some privlage problems, but i don't think so.

Here is where i'm at now. I had been able to view the php info with the "html" tag <?php phpinfo(); ?> and everything worked great. I check another php page and get a "This PHP CGI binary was compiled with force-cgi-redirect enabled...." message. So i read online and see that i need to turn off the "cgi.force_redirect" (cgi.force_redirect = 0) and now i get "page cannot be displayed" grrrrrr.

I've been through numerous pages and forums looking for a simple answer, can anyone please help with any suggestions on what might be wrong
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23469
  • Loc: Woodbridge VA

Post 3+ Months Ago

These instructions from the php manual may help you. Looks like there may be a couple other additional steps besides changing the one variable.

In order to run php scripts with php.exe CGI instead of php4isapi.dll under IIS, following steps can be followed.

i) Add a web service extension for PHP using IIS manager. Choose a web service extension name like 'PHP' and add your php.exe path in the 'file location' while adding the required file e.g. 'C:\php\php.exe' in the Add extension dialog box. Don't forget to 'Allow' the extension file.

ii) Open php.ini file located at %systemroot%. Set the following variables to the shown values.

cgi.force_redirect = 0
cgi.redirect_status_env = ENV_VAR_NAME

iii) In your websites, add Application Mapping for '.php' and set the executable path to your php.exe file path.

You can test whether PHP is running or not and other PHP settings using the following simple PHP script.


Feroz Zahid
ferozzahid [_at_] usa [_dot_] [_com_]

Post Information

  • Total Posts in this topic: 2 posts
  • Users browsing this forum: No registered users and 10 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum

© 1998-2017. Ozzu® is a registered trademark of Unmelted, LLC.