MVC 4 Default Parameter Value
问题 In MVC 4 application while defining routing I can provide a list of default parameters. What value shall I provide for optional parameter: UrlParameter.Optional or empty string ? Examples: routes.MapRoute("simple", "{controller}/{action}/{id}", new {controller = "Home", action = "Index", id = UrlParameter.Optional}); routes.MapRoute("simple", "{controller}/{action}/{id}", new {controller = "Home", action = "Index", id = ""}); Is there any difference between id = "" and id = UrlParameter