title: Enable mod_deflate to send Content-Encoding: gzip
body: <p><strong>EDIT</strong> I have found that the problem is actually <a href="http://code.google.com/p/minify/" rel="noreferrer">php minify</a>. This was sending the deflated content instead of Apache. I'll find more on this.</p>
  
  <p>According to <a href="http://oreilly.com/catalog/9780596529307/" rel="noreferrer">High Performance Web Sites</a>, if I enable mod_deflate in Apache 2.x, by adding the following line, it should send gzipped/delfated content: -</p>
  
  <pre><code>AddOutputFilterByType DEFLATE text/html text/css application/x-javascript
  </code></pre>
  
  <p>The book also says that <code>gzip</code> is more effective than <code>deflate</code>.</p>
  
  <p>I have enabled in httpd.conf by adding the same line. But Apache sends <code>Content-Encoding: deflate</code>.</p>
  
  <p>I tested with CURL using: -</p>
  
  <pre><code>curl -i -H "Accept-Encoding: gzip" "http://192.168.1.33/s.js" &gt;&gt; e:\curl_log.txt
  </code></pre>
  
  <p>It returns 'gzipped' content. But when I send the command: -</p>
  
  <pre><code>curl -i -H "Accept-Encoding: gzip, deflate" "http://192.168.1.33/s.js" &gt;&gt; e:\curl_log.txt
  </code></pre>
  
  <p>It returns 'deflated' content.</p>
  
  <p>So, if the browser supports both deflated and gzipped, Apache send deflated. How to tell Apache to prefer gzip over deflate?</p>
  
  <p>FYI: -</p>
  
  <ul>
  <li>I could not find anything in:
  <a href="http://httpd.apache.org/docs/2.0/mod/mod_deflate.html" rel="noreferrer">http://httpd.apache.org/docs/2.0/mod/mod_deflate.html</a>.   </li>
  <li>There is no occurrence of no-gzip in
  the Apache conf.</li>
  <li>Server: Apache/2.2.9 (Win32) PHP/5.2.6</li>
  <li>FF sends request header as: "Accept-Encoding: gzip, deflate"</li>
  </ul>