简体   繁体   中英

Why doesn’t url rewrite work in server

In asp.net 3.5, I'm rewriting the url

    http://www.dotoobeta/blogs/1108

to the following

    http://www.dotoobeta/blogs/blogs.aspx

I am using the UrlRewritingNet.UrlRewriter.dll and it works fine locally, but it is not work on my other server. I already modified the configuration in IIS also.

What is the solution?

Perhaps your server is not configured to route requests like http://www.dotoobeta/blogs/1108 through ASP.NET pipeline. If you have IIS 6 or higher on the server, you can configure wildcard handler and handle everything via ASP.NET. Don't forget to uncheck "verify that file exists" checkbox, or it won't work for nonexisting paths.

I have similar problem, and it's caused by architecture. I must add mapping for 64 bit too like this :

  <add name="aspnet_isapi"    path="*" verb="*" modules="IsapiModule" scriptProcessor="%windir%\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll" resourceType="Unspecified" requireAccess="None" preCondition="classicMode,runtimeVersionv2.0,bitness32" />
  <add name="aspnet_isapi-64" path="*" verb="*" modules="IsapiModule" scriptProcessor="%windir%\Microsoft.NET\Framework64\v2.0.50727\aspnet_isapi.dll" resourceType="Unspecified" requireAccess="None" preCondition="classicMode,runtimeVersionv2.0,bitness64" />

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM