title: MvcMiniProfiler results request giving 404 in Asp.Net MVC app
body: <p>I am trying to use the MvcMiniProfiler in my Asp.Net MVC application.  I installed the latest NuGet package and added all the code from the wiki page into <code>Application_BeginRequest()</code>, <code>Application_AuthenticateRequest()</code> and in my view.</p>
  
  <p>Upon loading the page, all of the mini profiler's javascript files are being included and correctly downloaded from the server, but when it attempts to get the results Chrome shows:</p>
  
  <pre><code>GET http://localhost:59269/mini-profiler-results?id=59924d7f-98ba-40fe-9c4a-6a163f7c9b08&amp;popup=1 404 (Not Found)
  </code></pre>
  
  <p>I assume this is due to no routes being setup with MVC to allow for the <code>/mini-profiler-results</code> however I cannot find a way to do that.  Looking at the Google code page, their <code>Global.asax.cs</code> file of their sample app has gone through several changes, with one time using <code>MvcMiniProfiler.MiniProfiler.RegisterRoutes()</code>, a second using <code>MvcMiniProfiler.MiniProfiler.Init()</code>, and a third style which does nothing of the sort.  The previously mentioned two functions do not exist, so I assume they have been phased out.</p>
  
  <p>At this point I'm unsure of how I can fix this error and use the profiler in my app.  Any ideas?</p>
  
  <hr>
  
  <p>My Global.Asax.cs file looks like:</p>
  
  <pre><code>public class Global : System.Web.HttpApplication
  {
      protected void Application_BeginRequest()
      {
          MvcMiniProfiler.MiniProfiler.Start();
      }
  
      protected void Application_AuthenticateRequest(Object sender, EventArgs e)
      {
          // Only show profiling to admins
          if (!Roles.IsUserInRole(Constants.AdminRole))
              MvcMiniProfiler.MiniProfiler.Stop(discardResults: true);
      }
  
      protected void Application_Start(object sender, EventArgs e)
      {
          AreaRegistration.RegisterAllAreas();
          RegisterRoutes(RouteTable.Routes);
      }
  
      public static void RegisterRoutes(RouteCollection routes)
      {
          routes.IgnoreRoute("{resource}.axd/{*pathInfo}");
          routes.IgnoreRoute("{resource}.aspx/{*pathInfo}");
  
          routes.MapRoute(
          "Default",
              // Route name
          "{controller}/{action}/{id}",
              // URL with parameters
          new { controller = "Home", action = "Index", id = "" }
              // Parameter defaults
          );
      }
  }
  </code></pre>