ASP.NET url伪静态 URLRewriter.dll,该怎么解决

ASP.NET url伪静态 URLRewriter.dll
XP IIS 5.0

IIS 已添加 .html 映射 ...


网站web.confg 配置
--------------------------------------------------
<configuration>
  <configSections>
  <section name="RewriterConfig" type="URLRewriter.Config.RewriterConfigSerializerSectionHandler, URLRewriter" />
  </configSections>

  <!-- 下面是配置重写URL规则 -->
  <RewriterConfig>
  <Rules>
  <RewriterRule>
  <LookFor>~/urlparam/AllUsres.html</LookFor>
  <SendTo>~/urlparam/AllUsres.html</SendTo>
  </RewriterRule>

  <RewriterRule>
  <LookFor>~/urlparam/UsersDetail_(\d{1,})\.aspx</LookFor>
  <!-- 这个是被代替后的文件名,使用到正则表达式 -->
  <SendTo><![CDATA[~/urlparam/UsersDetail.aspx?uid=$1]]></SendTo>
  <!-- 这个是要给代替的网页,一般是带有问号后面带参数的网页 
  访问如: http://localhost/urlparam/UsersDetail_1.aspx 原型为 UsersDetail.aspx?uid=1
  -->
  </RewriterRule>
  </Rules>
  </RewriterConfig>

  <appSettings/>

  <system.web>
  <httpModules>
  <add type="URLRewriter.ModuleRewriter, URLRewriter" name="ModuleRewriter" />
  </httpModules>
  <httpHandlers>
  <add verb="*" path="*.aspx" type="URLRewriter.RewriterFactoryHandler, URLRewriter" />
  <add verb="*" path="*.html" type="URLRewriter.RewriterFactoryHandler, URLRewriter" />
  </httpHandlers>

  <compilation debug="false" />
  <authentication mode="Windows" />
  </system.web>
</configuration>



用户详细页面 uid 参数。。。


为什么 IIS 浏览页面后,还是原来 .aspx 的url 而不是 .html ,我哪里搞错了 、、、

------解决方案--------------------
XML code

<configSections>
<section name="CustomConfiguration" type="URLRewriter.Config.UrlsSection, URLRewriter"/>
</configSections>

<CustomConfiguration>
    <urls>
      <add virtualUrl="~/Index.htm" destinationUrl="~/Index.aspx"/>
      <add virtualUrl="~/about.htm" destinationUrl="~/About.aspx"/>
    </urls>
  </CustomConfiguration>

<httpModules>
 <add type="URLRewriter.RewriterModule, URLRewriter" name="RewriterModule"/>
</httpModules>

------解决方案--------------------
是否配置了IIS?
------解决方案--------------------
.net4.0的话强烈建议使用内置的url路由功能了。
------解决方案--------------------
映射了URLRewriter.dll 这个,你IIS重新启动了吗
------解决方案--------------------
我上个星期也遇到过这样的情况
这和你的IIS设置没有关系。完全不应该使用:URLRewriter.dll

应该使用:UrlRewritingNet.UrlRewriter.dll
web.config
C# code
<configSections>
    <!--伪静态开始-->
    <section name="urlrewritingnet" requirePermission="false" type="UrlRewritingNet.Configuration.UrlRewriteSection, UrlRewritingNet.UrlRewriter"  />
    <!--伪静态结束-->
  </configSections>
<system.web>
<httpModules>
      <!--伪静态开始-->
      <add name="UrlRewriteModule" type="UrlRewritingNet.Web.UrlRewriteModule, UrlRewritingNet.UrlRewriter"/>
      <!--伪静态结束-->
    </httpModules>
</system.web>

  <urlrewritingnet configSource="Config\UrlRewriteSettings.config" />