title: Javascript compression via .htaccess?
body: <p>I'm using Apache.</p>
  
  <p>I'm auto gzipping my HTML &amp; CSS files on the fly using the following directive in my .htaccess file.</p>
  
  <pre><code># Enable ETag
  FileETag MTime Size
  
  
  # Set expiration header
  ExpiresActive on
  ExpiresDefault "access plus 1 year"
  ExpiresByType image/gif A2592000
  ExpiresByType image/png A2592000
  ExpiresByType image/jpeg A2592000
  ExpiresByType text/css A2592000
  ExpiresByType text/javascript A2592000
  ExpiresByType text/js A2592000
  
  
  # Compress some text file types
  AddOutputFilterByType DEFLATE text/html text/css text/xml application/x-javascript text/javascript text/js
  
  
  # Deactivate compression for buggy browsers
  BrowserMatch ^Mozilla/4 gzip-only-text/html
  BrowserMatch ^Mozilla/4\.0[678] no-gzip
  BrowserMatch \bMSIE !no-gzip !gzip-only-text/html
  </code></pre>
  
  <p>However, when I use the Firebug plugin for Firefox, I notice that my javascript files are NOT being gzipped (only my HTML and CSS files are).</p>
  
  <p><strong>Any ideas why my JavaScript files are not being gzipped on the fly by Apache?</strong></p>