Do most shared hosts handle gzipped files?
Posted
by Matrym
on Stack Overflow
See other posts from Stack Overflow
or by Matrym
Published on 2010-04-21T10:41:41Z
Indexed on
2010/04/21
10:43 UTC
Read the original article
Hit count: 238
I get them theoretically, but I'm grappling with gzipping files in practice. How should I go about gzip compressing my files, and what needs to be done in order to use them on a shared host?
Would the following work?
RewriteEngine On
RewriteBase /
RewriteCond %{HTTP:Accept-Encoding} .*gzip.*
RewriteRule ^/(.*)\.js$ /$1.js.gz [L]
RewriteRule ^/(.*)\.css$ /$1.css.gz [L]
AddEncoding x-gzip text.gz
© Stack Overflow or respective owner