IIS7.5 自定义Html/shtml/htm...后缀映射

以添加html后缀的文件的 映射为例:

1.打开iis管理器,点击

2.点击打开处理程序映射

3.添加托管处理程序映射

4.请求路径 *.html  类型: System.Web.UI.PageHandlerFactory  名称:Html-Integrate  确定

5.添加处理脚本映射

6.请求路径 *.html  可执行文件为:C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll (请根据具体情况修改)  名称:htmlRequest(随意)

 

 7.重启IIS

 

Appcmd.exe命令实现:

%windir%\system32\inetsrv\appcmd set config /section:handlers /+[name='Html-Integrate',path='*.html',verb='GET,HEAD',type='System.Web.UI.PageHandlerFactory',preCondition='integratedMode']

  

 

posted on 2014-05-02 11:18  iackjee  阅读(5982)  评论(0编辑  收藏  举报

导航