I want to get the parameter from a url as below:
www.domain.com/Controller/Action/Parameter
In my controller:
public ActionResult Action()
{
//some codes
}
User enters url as above and should navigate the the specific controller. How do I get the 'Parameter' in the Action of my controller?
public ActionResult Action(string id)assuming your using the default route (in your example, the value ofidwill be"Parameter")