PHP on IIS 6 in Vista


Recommended Posts

I know how to install PHP on the old IIS interface through the ISAPI filters, and I already have php.ini configured properly, but I can't seem to figure out how to get it working on this IIS interface. The only tutorial I have seen with this IIS interface had more icons, such as ISAPI filters. I have tried every combination possible with Handlers and Modules but I just can't get it to work. Does anyone have a tutorial or something?

screenqn8.jpg

Link to comment
https://www.neowin.net/forum/topic/541292-php-on-iis-6-in-vista/
Share on other sites

I managed to set this up a while ago, but can't check my configuration because my vista machine decided to break, but I think you have to click on "Handler Mappings" and then on the right hand side click on "Add Script Map", and then just enter the file extensions that you want php to parse like *.php and then enter the location of the php isapi file.

I've installed php5 (you need 5) and mysql5 (you need 5) on two vista ultimates, on the 2nd it behaves a tiny bit differently with the fastcgi, but works nontheless.

mysql5 works fine, no special instructions, for php5 you download the .zip, and then do some funky stuff in iis7 which you can find on google via some dudes blog.

Ok, MioTheGreat helped me out a lot, but I'm still at a roadblock. I should let it be known that I'm running x64.

Anyway, I fixedd that error, and it looks like it's configured just fine in IIS, but I'm getting a 503 Service Unavailable error.

In the event logs, the details are "Failed to find the RegisterModule entrypoint in the module DLL C:\Inetpub\php\php5isapi.dll. The data is the error."'

Yeah, this is pretty much just a never ending maze of errors for me. I checked the application pool defaults and changed it too allow 64 bit code, which fixed one problem, but now it's asking to download the .php file, which means PHP isn't installed obviously. Oof. I'll post results when I fix it.

I guess I'm only talking to myself now but basically what had happened was before I was looking at any tutorials, I was screwing with stuff myself. My original problem was it wasn't executing the .dll in 32 bit mode. While i was trying to fix that problem I tried screwing with the modules. So once I fixed the 32 bit error, it was still having trouble with a module. Even though said module wasn't even active or enabled, it was still trying to access the ISAPI dll.

Anyway, it works now and I feel great.

Thanks for the links!

  • 2 weeks later...

problem with isapi modules on IIS7 is that the phuckers at MS set IIS to work in x32 bit compatibility mode by default. To install php x64 on IIS execute the following command:

cscript %SYSTEMDRIVE%\inetpub\adminscripts\adsutil.vbs SET W3SVC/AppPools/Enable32bitAppOnWin64 0

To avoid probs with the integrated pool, open Inetpub\wwwroot\web.config and set <identity impersonate="true" /> to false

to use the integrated DefaultAppPool first go to Windows\System32\lusrmgr.msc and give the IUSR_ admin rights, then set a pass for this user and set this user as the standard user in the IIS snap-in, provide name+pass

to install php, first add the following variables to the environment:

PATH: C:\Program Files\Server\PHP

PHPRC: C:\Program Files\Server\PHP

Then:

ISAPI Fiter:

PHP

C:\Program Files\Server\PHP\php5isapi.dll

Handler:

*.php

C:\Program Files\Server\PHP\php5isapi.dll

Isapi und CGI-Restrictions:

C:\Program Files\Server\php\php5isapi.dll

PHP

allow all (remove restrictions)

to install the IIS https SSL-certificate:

get OpenSSL, inofficial x64 exes are available

create empty database.txt in the bin directory

create serial.txt, first line: 01, second line: empty

adjust the paths in the openssl.cnf file

then:

openssl genrsa -des3 -out IIS.key 1024

openssl req -config openssl.cnf -new -x509 -days 3650 -key IIS.key -out IIS.cer

create certificate request in the IIS7 Snap-in, save to certreq.txt in the openssl bin directory

then:

openssl ca -config openssl.cnf -cert IIS.cer -in certreq.txt -keyfile IIS.key -days 3650 -out IIS7.cer

openssl x509 -in IIS7.cer -out IIS7_509.cer

then:

navigate to the certificates manager: Windows\System32\certmgr.msc

install the certificate into the trusted authorities store (second from the top)

proceed with the certificate request in IIS snap-in - it wants the IIS7.cer file

then:

create SSL-bindings in the IIS-snapin (127.0.0.1:443, select your certificate)

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.