I determined the following route
routes.MapRoute( "ItemName", "{controller}/{action}/{projectName}/{name}", new { controller = "Home", action = "Index", name = "", projectName = "" } );
This route really works, so if I find in the browser
/Milestone/Edit/Co-Driver/Feature complete
It correctly proceeds to the Milestone controller, the editing action, and passes the values.
However, if I try to build a link in a view with url.action -
<%=Url.Action("Edit", "Milestone", new {name=m.name, projectName=m.Project.title})%>
I get the following URL
Milestone/Edit?name=Feature complete&projectName=Co-Driver
It still works, but not very clean. Any ideas?
source share