Example #1
0
        public static void RegisterRoutes(RouteCollection routes)
        {
            routes.IgnoreRoute("{resource}.axd/{*pathInfo}");
            routes.IgnoreRoute("Content/{*pathInfo}");
            routes.IgnoreRoute("Scripts/{*pathInfo}");

            RoutingRegistrator.Register(routes);


            routes.MapRoute(
                "ListDefault",
                "{controller}/List",
                new { controller = "Home", action = "List" },
                new[] { Const.Common.ControllerNamespace }
                );

            routes.MapRoute(
                "CmsDefault",
                "{controller}/{action}/{id}",
                new { controller = "Home", action = "Index", id = "" },
                new[] { Const.Common.ControllerNamespace }
                );

            routes.MapRoute(
                "Home",
                "",
                new { controller = "Home", action = "Index", id = "" },
                new[] { Const.Common.ControllerNamespace }
                );
        }
Example #2
0
        public static void RegisterRoutes(RouteCollection routes)
        {
            RoutingRegistrator.Register(routes);

            routes.MapRoute(
                "Home",
                "",
                new { controller = "Home", action = "Index", id = "" }
                );

            routes.MapRoute(
                "Default",
                "{*url}",
                new { controller = "Page", action = "Process", url = "" }
                );
        }