As i read about url routing from : http://www.codethinked.com/post/2008/08/20/Exploring-Syste开发者_StackOverflow中文版mWebRouting.aspx
I found , "Each url coming into the application will be matched against the list of Routes that you have defined, and if one matches then it will be used"
Is this means we can define our own patterns of urls? except "Controller//Action//ID" ?
http://www.asp.net/mvc/tutorials/creating-custom-routes-cs
http://weblogs.asp.net/scottgu/archive/2007/12/03/asp-net-mvc-framework-part-2-url-routing.aspx
Is this means we can define our own patterns of urls? except "Controller//Action//ID" ?
Yes you can, search for Routes / RouteCollection and you should find plenty of info.
Also that default route is defined in your code, see the global.asax in the default asp.net mvc site you get when creating a new project.
精彩评论