15.4 Defining Default Values; Listing 15-9 Providing a Default Value in RouteConfig.cs File
parent
3ddca950e3
commit
cf7a377fe0
|
@ -11,7 +11,8 @@ namespace UrlsAndRoutes
|
|||
{
|
||||
public static void RegisterRoutes(RouteCollection routes)
|
||||
{
|
||||
routes.MapRoute("MyRoute", "{controller}/{action}");
|
||||
routes.MapRoute("MyRoute", "{controller}/{action}",
|
||||
new { action = "Index"});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue