15.4 Defining Default Values; Listing 15-9 Providing a Default Value in RouteConfig.cs File
This commit is contained in:
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…
x
Reference in New Issue
Block a user