There are many ways to speed up the Magento, and using the. htaccess file to turn on gzip compression can be very noticeable for magento acceleration. The. htaccess file is already included in the Magento initial installation, and we only need to comment out some of the instructions in the. htaccess file. Specific
There are many ways to speed up the Magento , and using the. htaccess file to turn on gzip compression can be very noticeable for magento acceleration. The. htaccess file is already included in the Magento initial installation, and we only need to comment out some of the instructions in the. htaccess file. Specific as follows. According to Inchoo's test, magento acceleration is done according to the following method, which is about 235% efficiency improvement.
# # Enable Apache served files compression
# # Http://developer.yahoo.com/performance/rules.html#gzip
# Insert Filter
Setoutputfilter DEFLATE
# Netscape 4.x has some problems ...
Browsermatch ^MOZILLA/4 gzip-only-text/html
# Netscape 4.06-4.08 has some more problems
Browsermatch ^mozilla/4\.0[678] No-gzip
# MSIE masquerades as Netscape, but it's fine
Browsermatch \bmsie!no-gzip!gzip-only-text/html
# Don ' t compress images
Setenvifnocase request_uri \. (?: gif|jpe?g|png) $ no-gzip dont-vary
# Make sure proxies don ' t deliver the wrong content
Header Append Vary user-agent env=!dont-vary
# Enable resulting HTML compression
Php_flag zlib.output_compression on
Let Magento accelerate with a. htaccess file