asp.net mvc - How to use MVC style routing while still keeping static page URLs intact? -


I have a web server that has existing pages in it that are built with basic static HTML. I want to leave them alone. Yes, but increase the site with some ASP.NET mvc pages. I want these pages to be accessible through the MVCL URL Routing Mechanism. But, ideally, I want to preserve the old static page URL without wanting to take all the static pages in the MVC app. What is the best way to accomplish this? Static files such as .html pages present on the disk directly served by the web server if you integrated the second integrated integrated mode. If you are hosting your application in, you can try adding the following route:

  route. Unknown route ("{file} .html");  

A physical file is present when the default routing is not present which routes.RouteExistingFiles = true; can be turned off.


Comments