|
IWebPageControllerBuilderUseCustomRoutes Method
|
Use the given function to configure custom routes for selecting pages.
Namespace: GSF.Web.HostingAssembly: GSF.Web (in GSF.Web.dll) Version: 2.4.194-beta
Syntaxfunction UseCustomRoutes(routeConfig);
Parameters
- routeConfig ActionHttpRouteCollection
- Function that configures the custom routes.
Return Value
IWebPageControllerBuilderThe web page controller builder.
Remarks
The routes should set the controller, action, and pageName as in the following example.
routes.MapHttpRoute(
name: "MyCustomRoute",
routeTemplate: "my/custom/route",
defaults: new
{
controller = "WebPage",
action = "GetPage",
pageName = "Index.html"
}
);
See Also