title: How do I disable gzip compression for flv files in IIS 7 with runAllManagedModulesForAllRequests set to true?
body: <p>I have an ASP.NET 3.5 Website that is running on IIS 7 and I would like to have my static content (like css files, javascript files, etc) gzip compressed as well as my dynamic content (.net pages). The problem is that I need to make sure flv files (flash video files) are not gzip compressed because that causes problems with the flash video player I'm using, <a href="http://flowplayer.org/" rel="noreferrer">Flowplayer</a>.</p>
  
  <p>I've added the following line to my web.config which enables compression, but then my flv files are also being gzip compressed:</p>
  
  <pre><code>&lt;urlCompression doStaticCompression="true" doDynamicCompression="true" /&gt;
  </code></pre>
  
  <p>I've tried to add the following to my web.config, but it did not change anything:</p>
  
  <pre><code>&lt;httpCompression&gt;
      &lt;staticTypes&gt;
          &lt;remove mimeType="video/x-flv"/&gt;
      &lt;/staticTypes&gt;
      &lt;dynamicTypes&gt;
          &lt;remove mimeType="video/x-flv"/&gt;
      &lt;/dynamicTypes&gt;
  &lt;/httpCompression&gt;
  </code></pre>
  
  <p>I have to turn off doDynamicCompression for the flv files not to be gzip compressed. I think that it is treating flv files as dynamic content because I have runAllManagedModulesForAllRequests="true" in my web.config (which I need for some of the things I'm doing with routing).</p>
  
  <p>In summary, how do I disable gzip compression for flv files?</p>