I want to create some SEO friendly URL.
Following is my Global.ascx entry:
routes.MapRoute( "Product", "{action}/{param1}/{id}", new { controller = "Home", action = "Index" }); routes.MapRoute( "Default", "{controller}/{action}/{id}", new { controller = "Home", action = "Index", id = UrlParameter.Optional });
First Mapping is because i don't want to display my controller name in url. Next Mapping is for rest of the URL.
Problem is there are some URL which gives me an error like:
http://localhost:1234/index/my-product-information/12 : PASS http://localhost:1234/contentcontrol/index : PASS http://localhost:1234/contentcontrol/index/12 : FAIL
here, index : ACTION NAME contentcontrol : Controller Name
How should i resolve this.
Thanks in advance.