PHP 4.4.9 for Windows Server 2003 (64bit) on IIS 6.0
by maxidea • 2009年05月12日 • 网络技术 • 1 Comment
PHP 4.4.9 for Windows Server 2003 (64bit) on IIS 6.0
Last update 2009-05-12 by SimonXu
Step 1: install PHP (Reference: http://blog.templatehome.cn/post/214):
1) unzip php-4.4.9-Win32 to E:\php
2) change the security for “E:\php” Properties:
Add “Everyone”, “IIS_WPG”, “Internet GUest Account(XXXserverName\IUSR_XXXserverName)” with permission “Full Control”
3) Copy a E:\PHP\php.ini-dist to C:\WINDOWS\php.ini and modify
extension_dir = “./” to extension_dir = “D:\php\extensions”
4) Copy “php4ts.dll” to “C:\WINDOWS\system32″ and change the security for its Properties:
Add “Everyone”, “IIS_WPG”, “Internet GUest Account(XXXserverName\IUSR_XXXserverName)” with permission “Full Control”
5) Copy “php4isapi.dll” to “C:\WINDOWS” and change the security for its Properties:
Add “Everyone”, “IIS_WPG”, “Internet GUest Account(XXXserverName\IUSR_XXXserverName)” with permission “Full Control”
6) Change the Environment PATH for windows by “My computer”->”Properties”->”Advanced”->”Environment Variables”->”System Variables” to modify “PATH”: add “E:\php;E:\php\dlls;E:\php\extensions;E:\php\sapi;” to the front of the PATH (!Important!)
Setp 2: Change IIS 6 from 64bit to 32bit support ASP.NET 2.0 to support ASP/HTML/PHP in a same time(Reference: http://support.microsoft.com/?id=894435)
1) change to 32 bit run this cmd:
cscript %SYSTEMDRIVE%\inetpub\adminscripts\adsutil.vbs SET W3SVC/AppPools/Enable32bitAppOnWin64 1
2) Open “Administrative Tools” -> “Internet Information Services (IIS) Manager”->”Web Sites”->”Properties”->”ISAPI Filters” change the 64bit filter to 32bit version:
Remote: ASP.NET_2.0.50727.0 (path: C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\aspnet_filter.dll)
Add: ASP.NET_2.0.50727.0(32) (path: C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\aspnet_filter.dll)
3) Add a new web service extensions for “ASP.NET_2.0.50727(32)” from “Internet Information Services (IIS) Manager”->”Web Service Extensions”->”Add a new web service extensions”->Extension Name: ASP.NET_2.0.50727(32) -> Require files: C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll and enable “Set extension status to Allowed”
4) Restart IIS by cmd:
net stop w3svc
net stop iisadmin /yes
net start iisadmin
net start w3svc
Step 3: Change IIS to support PHP:
1) Add a new web service extensions for PHP from “Internet Information Services (IIS) Manager”->”Web Service Extensions”->”Add a new web service extensions”->Extension Name: PHP4 -> Require files: C:\WINDOWS\php4isapi.dll and enable “Set extension status to Allowed”
2) Open “Internet Information Services (IIS) Manager”->”Web Sites”->”Default Web Site”->”Properties”->”ISAPI Filters” and add a PHP filter by name: php, Executable: C:\WINDOWS\php4isapi.dll (after reset IIS, the status should be turn to “Loaded”)
3) Open “Internet Information Services (IIS) Manager”->”Web Sites”->”Default Web Site”->”Properties”->”Home Directory”->”Configuration…” to add a “.php” extension by “Executable: C:\WINDOWS\php4isapi.dll” and let other setting as default.
4) Reset IIS by cmd : iisreset
That’s all, enjoy~

Great post! Just wanted to let you know you have a new subscriber- me!