我刚开始研究 ASP.net MVC。我在 Global.asax 中找到了以下代码。我知道这段代码用于管理应用程序中的路由。但是,我无法理解这段代码:
***routes.IgnoreRoute("{resource}.axd/{*pathInfo}");***
public static void RegisterRoutes(RouteCollection routes)
{
***routes.IgnoreRoute("{resource}.axd/{*pathInfo}");***
routes.MapRoute(
"Default", // Route name
"{controller}/{action}/{id}", // URL with parameters
new { controller = "Home", action = "Index", id = UrlParameter.Optional } // Parameter defaults
);
}
第一行我不清楚..谁能解释一下它的确切目的是什么?