When you create a ASP.NET MVC 2 web application in Visual Studio, it gives you a default MVC site. It shows 2 menus [Home] and [About]. When you hover these menus it gives you this URL:
- [Home] localhost:1234/
- [About] localhost:1234/Home/About
Why is About under Home?
I want menu links like
- [Home] localhost:1234/
- [About] localhost:1234/About
How can I do this?
About is under Home because it’s an action under the HomeController.
If you want to access about using /About, set up a new route in your Global.asax. Example: