Wen*_*ong 3 asp.net iis-7 url-rewriting http-status-code-404
我已经实现了" 方法3:使用HttpModule从IIS7执行无扩展URL重写 ": - http://weblogs.asp.net/scottgu/archive/2007/02/26/tip-trick-url -rewriting-与-ASP-net.aspx
这是基于URLRewriter模块: - http://urlrewriter.net/
它似乎适用于我的本地环境,但在生产服务器(运行IIS 7)上它显示" 404 - 文件或目录未找到 "页面.
我在Google上搜索过,似乎无法找到解决方案.
最后,我们回到IIS 6并按照此处的说明进行操作: - http://urlrewriter.net/index.php/support/installation/windows-server-2003
但是有一天我们可能不得不在共享托管环境中升级到IIS 7,同样的问题将再次出现!
托管伙伴让它在IIS 7中工作.HTTP处理程序需要使用不同应用程序池的通配符映射,以使其在IIS 7中工作.希望这会有所帮助.
确保在Web.Config中包含以下内容:
<system.webServer>
<validation validateIntegratedModeConfiguration="false"/>
<handlers>
<add name="wildcard" path="*" verb="*" modules="IsapiModule" scriptProcessor="%windir%\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll" resourceType="Unspecified" requireAccess="None" preCondition="classicMode,runtimeVersionv2.0,bitness32" />
</handlers>
</system.webServer>
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
8337 次 |
| 最近记录: |