Force gzip compression for all relevant file types.


/ Published in: Apache
Save to your folder(s)

These tweaks improved my Yslow score from F to B.


Copy this code and paste it in your HTML
  1. # Compress all text, html, css, and javascript:
  2. AddOutputFilterByType DEFLATE text/html text/plain text/xml text/css text/javascript
  3.  
  4. # Or, compress certain file types by extension:
  5. <Files *.html>
  6. SetOutputFilter DEFLATE
  7. </Files>

URL: http://betterexplained.com/articles/how-to-optimize-your-site-with-gzip-compression/

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.