In my site.master, i need to be able to rewrite the current route to match a mobile site.
Basically i need to be able to do this:
<%= Url.RouteUrl("home", new { controller = "Home", action = "Index", environment = "d1" })%>
but i need to know the route name and values on each page request
Jousterling
In case anyone is still wondering how to do this, apparently you can’t get the route name
from Phil Haack:
http://haacked.com/archive/2010/11/28/getting-the-route-name-for-a-route.aspx
but you can register a data token with the route name and then extract that later.