title: .Net 4 Routing not working properly on IIS6 (Stylesheet/Image Intercept)
body: <p>I have a mobile website, intercepting the stylesheet/images and setting sizes relative to the device. I have been testing it on IIS7 and works fine.</p>
  
  <p>The live site is IIS6 (lil surprise)...</p>
  
  <p>Normal routing for <em>friendly urls</em> works fine, but the stylesheet/images intercept is not doing anything.</p>
  
  <p>Here is a snippet of my global.asax routing section :</p>
  
  <pre><code>public static void RegisterRoutes(RouteCollection routes)
  {
                  routes.RouteExistingFiles = true;
  
                  routes.MapPageRoute("ImageResizerS", "images/{Sub}/{Path}", "~/Site_Handlers/ImageResize.ashx");
                  routes.MapPageRoute("ImageResizer", "images/{Path}", "~/Site_Handlers/ImageResize.ashx");
  
                  routes.MapPageRoute("StyleSheetIntercept", "Styles/{Path}", "~/Site_Handlers/InterceptStyleSheet.ashx");
  
                  routes.MapPageRoute("Landing page", "", "~/Site_Files/LandingPage.aspx");
      }
  </code></pre>
  
  <p><strong>What seems to be the problem?</strong></p>
  
  <p><em>What I have noticed :</em></p>
  
  <p>When I set <code>routes.RouteExistingFiles = true;</code> to <strong><code>false</code></strong>. It creates the same behavior on IIS7 &amp; IIS6...no intercept. </p>