-
AuthorPosts
-
December 29, 2015 at 12:05 pm #724534
HI, folowing your recommendations on performance I want to add GZIP compression but I am not sure what I did is right in the file so here it is:
# Use PHP5.4 as default
AddHandler application/x-httpd-php54 .php# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ – [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule><IfModule mod_deflate.c>
# Force compression for mangled headers.
# http://developer.yahoo.com/blogs/ydn/posts/2010/12/pushing-beyond-gzipping
<IfModule mod_setenvif.c>
<IfModule mod_headers.c>
SetEnvIfNoCase ^(Accept-EncodXng|X-cept-Encoding|X{15}|~{15}|-{15})$ ^((gzip|deflate)\s*,?\s*)+|[X~-]{4,13}$ HAVE_Accept-Encoding
RequestHeader append Accept-Encoding “gzip,deflate” env=HAVE_Accept-Encoding
</IfModule>
</IfModule># Compress all output labeled with one of the following MIME-types
# (for Apache versions below 2.3.7, you don’t need to enablemod_filter
# and can remove the<IfModule mod_filter.c>
and</IfModule>
lines
# asAddOutputFilterByType
is still in the core directives).
<IfModule mod_filter.c>
AddOutputFilterByType DEFLATE application/atom+xml \
application/javascript \
application/json \
application/ld+json \
application/rss+xml \
application/vnd.ms-fontobject \
application/x-font-ttf \
application/x-web-app-manifest+json \
application/xhtml+xml \
application/xml \
font/opentype \
image/svg+xml \
image/x-icon \
text/css \
text/html \
text/plain \
text/x-component \
text/xml
</IfModule></IfModule>
# END WordPressCan you tell me if I have well placed the additional code as I still see remarks about adding GZIP from the test I am doing with google developer tools in Chrome. See snapshot attached.
December 29, 2015 at 6:20 pm #724851Hey there,
We’re sorry but we do not have support for server setup. Our performance article serves only as a guide. If you’re not sure, it is best to seek assistance from a WordPress developer.
Thank you for understanding.
December 30, 2015 at 12:49 am #725160OK. Thank you.
December 30, 2015 at 12:52 am #725164You’re welcome.
December 30, 2015 at 1:09 am #725172I found this link to allow testing of GZIP and it seems ok for my site.
https://varvy.com/tools/gzip/Something you may re-use if somebody else ask you the same 😉
December 30, 2015 at 1:10 am #725174Thanks for sharing the link.
-
AuthorPosts