Skip to content

Instantly share code, notes, and snippets.

@klpatil
Created April 6, 2016 10:32
Show Gist options
  • Save klpatil/04bb942f5288e955522fd7f0ce0e5f42 to your computer and use it in GitHub Desktop.
Save klpatil/04bb942f5288e955522fd7f0ce0e5f42 to your computer and use it in GitHub Desktop.
using Sitecore.Pipelines;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using System.Web.Routing;
namespace SC.Website.Web.App_Start
{
public class RegisterMvcRoutes
{
public virtual void Process(PipelineArgs args)
{
this.RegisterRoutes(RouteTable.Routes);
}
public bool MvcIgnoreHomePage { get; set; }
protected virtual void RegisterRoutes(RouteCollection routes)
{
if (this.MvcIgnoreHomePage)
{
routes.IgnoreRoute(String.Empty);
}
RouteTable.Routes.MapRoute("JobSearch",
"JobSearch/GetJobFilters",
new { controller = "JobSearch", action = "GetJobFilters" });
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment