I have this route defined:
routes.MapRoute(
"Details", // Route name
"{home}/{details}/{id}/{name}", // URL with parameters
new
{
controller = "Home",
action = "Details",
id = UrlParameter.Optional,
name = UrlParameter.Optional
} // Parameter defaults
);
The ActionLink:
@Html.ActionLink("Show Details", "Details", "MyController", new { id = 1, name ="a" })
The actionlink results in /Home/Details/1?name=a
I am after /Home/List/1/a