Here’s a quick way to set the active class on the current URL with a .Net MVC application.
1. Set a string variable equal to the request path at the top of the layout or view:
@{
string path = Context.Request.Path;
}
2. Check the path variable against whatever the