windows 2003能安装IIS7吗

windows 2003能安装IIS7吗,第1张

想在windows 2003中好好跑php,又要节省内存,真是很为难的事情,考虑到IIS7.5 Express可以在WIN2003上跑,不但能以fastcgi的方式支持php,还自带Rewrite组件,只需简单改改web.config的rule规则就可以了。 于是下载了IIS7.5 Express后,安装,还需要对applicationHost.config进行配置,首先得找到这个文件在哪里,如果能在"我的文档"中IIS7Express目录下找到,那就是它了,否则应该就是在IIS7 Express的安装目录下。 1、先修改:defaultDocument节,加入 <add value="index.php" /> <defaultDocument enabled="true"> <files> <add value="Default.htm" /> <add value="Default.asp" /> <add value="index.htm" /> <add value="index.html" /> <add value="iisstart.htm" /> <add value="default.aspx" /> <add value="index.php" /> </files> </defaultDocument> 2、找到fastcgi节。 <fastCgi> <application fullPath="C:phpphp-cgi.exe" monitorChangesTo="php.ini" activityTimeout="600" requestTimeout="600" instanceMaxRequests="10000"> <environmentVariables> <environmentVariable name="PHP_FCGI_MAX_REQUESTS" value="10000" /> <environmentVariable name="PHPRC" value="C:Program Files (x86)iis expressPHPv5.4" /> </environmentVariables> </application> </fastCgi> 3、找到handlles,加入 <add name="PHP_FastCGI" path="*.php" verb="GET,HEAD,POST" modules="FastCgiModule" scriptProcessor="C:PHPphp-cgi.exe" resourceType="Either" /> 尤其要注意的一是,这一句最好加在最前面,也就是在<handlles>下面的第一句,避免被其它Handle抢先处理了。 以上配置中,C:phpphp-cgi.exe 的部分替换成自己的php文件夹中的php-cgi.exe的位置。 4、在<site>配置节下,直接修改站点信息,或直接用appcmd.exe add site来添加站点。 5、找到诸如wordpress的安装文件夹,创建一个web.config文件,在configuration配置节下,添加Gzip压缩规则。 <system.webServer> <urlCompression doStaticCompression="true" doDynamicCompression="true" /> </system.webServer> 6、同样在web.config中,Wordpress的rewrite完整的web.config文件内容如下: <configuration> <system.webServer> <rewrite> <rules> <rule name="wordpress" patternSyntax="Wildcard"> <match url="*" /> <conditions> <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" /> <add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" /> </conditions> <action type="Rewrite" url="index.php" /> </rule> </rules> </rewrite> </system.webServer> <system.webServer> <urlCompression doStaticCompression="true" doDynamicCompression="true" /> </system.webServer> </configuration> 这样就完全配置完毕了,然后在IIS7 Express目录下,找到IISExpress.exe,直接双击运行,或者用命令行来执行指定加载哪个站点. iisexpress.exe /site:'站点名称1" iisexpress.exe /site:'站点名称2" 访问一下,就会发现访问速度比在windows下使用apache要快得多,而且少跑一个nginx,内存占用整体上也少了很多。

题主是否想询问“win2003提示setupis这种情况怎么办”?

1、首先,先打开win2003提示setupis的界面。

2、其次,到BIOS中更改硬盘模式为兼容模式。

3、最后安装好WIN2K3后安装硬盘驱动后再到BIOS中更改回来,就可以了。


欢迎分享,转载请注明来源:内存溢出

原文地址:https://54852.com/bake/11608641.html

(0)
打赏 微信扫一扫微信扫一扫 支付宝扫一扫支付宝扫一扫
上一篇 2023-05-17
下一篇2023-05-17

发表评论

登录后才能评论

评论列表(0条)

    保存