Apache - mod deflate - включаем gzip сжатие через .htaccess
Материал из Wiki - Iphoster - the best ever hosting and support. 2005 - 2025
Apache - mod deflate - включаем gzip сжатие через .htaccess
Проверяем или включен сам модуль для Apache:
# httpd -M | grep deflate deflate_module (shared)
Добавить в .htaccess файл:
<ifModule mod_deflate.c>
<IfModule mod_filter.c>
AddOutputFilterByType DEFLATE text/plain text/html
AddOutputFilterByType DEFLATE text/css
AddOutputFilterByType DEFLATE text/javascript application/javascript application/x-javascript
AddOutputFilterByType DEFLATE text/xml application/xml application/xhtml+xml application/rss+xml
AddOutputFilterByType DEFLATE application/json
AddOutputFilterByType DEFLATE application/vnd.ms-fontobject application/x-font-ttf font/opentype image/svg+xml image/x-icon
</ifModule>
</ifModule>
