Click here to Skip to main content
15,902,447 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
In my asp.net web-form web-site I want to remove .aspx at the end of url. for that i use following code in global.cs but is is not working plz help.


void RegisterRoutes(RouteCollection routes)
{
routes.MapPageRoute("All Product", "Products/All", "~/AllProduct.aspx");
routes.MapPageRoute("Selected Product", "Products/Selected/{name}", "~/ParticularProduct.aspx");
}

What I have tried:

void RegisterRoutes(RouteCollection routes)
{
routes.MapPageRoute("Login", "Login", "~/Login.aspx");

}
Posted
Updated 4-Jul-16 1:33am

1 solution

 
Share this answer
 
Comments
Kishor-KW 4-Jul-16 8:27am    
ok for this i have to use friendlyurl dll. but am i did any mistek in my above code?
Kornfeld Eliyahu Peter 4-Jul-16 8:31am    
I do not see the whole so not sure...
Check here: https://msdn.microsoft.com/en-us/library/dd329551(v=vs.100).aspx

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900