Assuming you've carried out steps 1 - 9 in the article you linked to and have your PHP files extracted to c:php
then complete the following steps using a cmd.exe
command prompt:
Firstly we need to configure IIS Express and setup a handler for PHP
cd "Program FilesIIS Express"
appcmd set config -section:system.webServer/fastCgi /+"[fullPath='C:PHPphp-cgi.exe',arguments='',maxInstances='4',idleTimeout='300',activityTimeout='30',requestTimeout='90',queueLength='1000',instanceMaxRequests='200',protocol='NamedPipe',flushNamedPipe='False',rapidFailsPerMinute='10']" /commit:apphost
appcmd set config -section:system.webServer/handlers /+"[name='PHP-FastCGI',path='*.php',modules='FastCgiModule',verb='*', scriptProcessor='c:phpphp-cgi.exe']" /commit:apphost
Assuming your PHP website resides in c:MyPHPWeb
we create a site in IIS Express that listens on http://localhost:32701
:
appcmd add site /name:"MyPHPApp" /bindings:http/*:32701: /physicalPath:"c:MyPHPWeb"
Next start the site:
iisexpress.exe /site:MyPHPApp
And finally browse to your PHP page:
http://localhost:32701/test.php
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…