Skip to content
gimmi edited this page Mar 22, 2012 · 2 revisions

ExtDirectHandler is implemented as a single System.Web.HttpHandler, so it should work with ASP.NET MVC without problems, you just have to inform MVC routing mechanism to ignore Ext Direct requests.

For example, if ExtDirectHandler has been configured for handling requests from "/rpc" address, add the following routing configuration in your Global.asax:

routes.IgnoreRoute("rpc/{*pathInfo}");

Other approach

  1. Create class:
public class DirectRouteHandler : IRouteHandler
{
    public IHttpHandler GetHttpHandler(RequestContext requestContext)
    {
        return new ExtDirectHandler.DirectHttpHandler();
    }
}
  1. Add following to the RegisterRoutes function in Global.asax.cs:
routes.Add(new Route("rpc/{*pathInfo}", new DirectRouteHandler()));
  1. No <httpHandlers> and routes.IgnoreRoute("rpc/{*pathInfo}") are required anymore.
Clone this wiki locally