MapRequestHandler - 404.0 Error while routing .html from .aspx to IIS 8.0

I use Rewriting URL in Asp.net framework 4.0 and I replace aspx with html extension (i.e. use routing like Login.aspx like Login.html). But it displays error 404 (not found). In short, URL rewriting with the .html extension does not work on IIS 8.0. Without .html (e.g. Login.aspx with login), it works fine.

Check this:

Please help me solve this problem.

Global.asax

 void Application_Start(object sender, EventArgs e) { RegisterRoutes(); } private static void RegisterRoutes() { System.Web.Routing.RouteTable.Routes.Add( "Login", new System.Web.Routing.Route("Login.html", new DisplayRouteHandler("~/Login.aspx"))); } 
+6
source share
1 answer

Changing the application pool from Classic to Integrated resolved the issue.

+3
source

All Articles