I assume that this means that you enable gzip compression for your css and js files, as this will allow the client to receive both gzip-encoded content and simple content.
Here's how to do it in apache2:
<IfModule mod_deflate.c>
Here's how to add the Vary Accept-Encoding header: [src]
<IfModule mod_headers.c> <FilesMatch "\.(js|css|xml|gz)$"> Header append Vary: Accept-Encoding </FilesMatch> </IfModule>
Vary: Header Vary: Indicates that the content served by this URL will change depending on the value of a particular request header. It says here that it will serve different content for clients that say they are Accept-Encoding: gzip, deflate (request header) than the content served to clients who do not send this header. The main advantage of this, AFAIK, is to let intermediate cache proxies know that they must have two different versions of the same URL due to such a change.
aularon Sep 04 '10 at 6:51 2010-09-04 06:51
source share