I have a form that represents a dropdown list of things. You select the desired thing and hit the okay button. It submits the form using a GET and the resulting URL is:
/Something/IdentificationInformation?jamesID=26
So I applied a routing rule:
routes.MapRoute(
name: null, // "Add James relationship"
url: "James/IdentificationInformation/{jamesID}",
defaults: new {
Controller = "James",
action = "IdentificationInformation"
}
);
but this url route does not get applied?
The form being submitted looks like this:
@using (Html.BeginForm("IdentificationInformation", "James", FormMethod.Get))
{
<div class="col-lg-9 col-md-9 col-sm-9 add-margin-top">
@Html.DropDownList("jamesID", new SelectList(Model, "JamesID", "Name"), new { id = "JamesDropdownList" })
</div>
<div class="col-lg-3 col-md-3 col-sm-3 add-margin-top">
@Html.ContinueButton("Continue")
</div>
}