iis8.0配置伪静态
最佳回答
:
01 <?xml version="1.0" encoding="UTF-8"?>
02<configuration>
03 <system.webServer>
04 <staticContent>
05 <mimeMap fileExtension=".bat" mimeType="text/bath" />
06 </staticContent>
07 <rewrite>
08 <rules>
09 <rule name="home Index">
10 <match url="^index.html$" ignoreCase="false" />
11 <action type="Rewrite" url="index.php" appendQueryString="false"/>
12 </rule>
13 <rule name="page Index">
14 <match url="^(.*)/index.html$" ignoreCase="false" />
15 <action type="Rewrite" url="{R:1}/index.php"appendQueryString="false" />
16 </rule>
17
18 <rule name="page List">
19 <match url="^(.*)page([0-9]+).html$" ignoreCase="false" />
20 <action type="Rewrite" url="{R:1}/index.php?gid={R:2}"appendQueryString="false" />
21 </rule>
22 <rule name="list Page">
23 <match url="^(.*)list-([0-9]+).html$" ignoreCase="false" />
24 <action type="Rewrite" url="{R:1}/.php?PageNo={R:2}"appendQueryString="false" />
25 </rule>
26 <rule name="show Page">
27 <match url="^(.*)show-aid([0-9]+).html$" ignoreCase="false" />
28 <action type="Rewrite" url="{R:1}/show.php?uid={R:2}"appendQueryString="false" />
29 </rule>
30
31 </rules>
32 </rewrite>
33 </system.webServer>
34</configuration>
第一步:
点击处理程序映射
(1)添加托管处理程序:
路径:*
类型:System.Web.UI.PageHandlerFactory
名称:v2_jiuxian.com_1PageHandlerFactory-Integrated-4.0
(2)编辑脚本映射:
我环境是64位,为了以防万一,我32位和64都配置了
32位
路径:*.html
可执行文件:%windir%http://Microsoft.NETFrameworkv4.0.30319aspnet_isapi.dll
名称:v2_jiuxian.com_2PageHandlerFactory-ISAPI-4.0_32bit
64位:
路径:*.html
可执行文件:%windir%http://Microsoft.NETFramework64v4.0.30319aspnet_isapi.dll
名称:v2_jiuxian.com_3PageHandlerFactory-ISAPI-4.0_64bit
(3)添加通配符脚本验证:
路径:*
可执行文件:%windir%http://Microsoft.NETFramework64v4.0.30319aspnet_isapi.dll
名称:v2.jiuxian.com_4PageHandlerFactory-ISAPI-4.0_64bit
以上的4个添加其实是把aspx的主件应用拷贝了一份.将其aspx改成html,
操作完以上4个项后返回,点击模块
(1)添加托管模块
名称:RewriterModule
类型:HttpHandler.URLRewriter.RewriterModule, HttpHandler
以上类型是你iis拦截器dll的路径啊,如空间名.类名
最新回答共有2条回答
-
建站最低500起
回复1、控制面板程序程序和功能
2、然后点击左侧的"打开或关闭windows功能"
3、在弹出的"windows功能"菜单中去掉"internet信息服务"下的"web管理工具"前面的选中状态。
4、在检查下"web管理工具"下面的所有子菜单是否有也有选中的。如果选中也取消选中状态。