Beanybux.com Support
Knowledgebase
Beanybux.com > Beanybux.com Support Center > Knowledgebase

Search help:


How to GZIP Your Site’s Content

Solution GZipping your content is the easiest and best way to speed up your site. For a full discussion about Gzipping content, If you just want the nitty gritty, without the technical explanations, as well as some real world results, let’s jump right into it.

The easiest way to gzip your content, if your site’s server supports it, is to throw one of these lines in your .htaccess file:

# compress all text & html:
AddOutputFilterByType DEFLATE text/html text/plain text/xml

# Or, compress by file extension:
<Files *.html>
SetOutputFilter DEFLATE
</Files>

Be sure to change the .html to .htm if you use that as your HTML file extension.

Or, if you don’t have access to your site’s .htaccess file, throw this PHP snippet at the top of every page (in WordPress, throw it in your header.php file):

<?php if (substr_count($_SERVER['HTTP_ACCEPT_ENCODING'], 'gzip')) ob_start("ob_gzhandler"); else ob_start(); ?>

After you’ve made the change, your site will be gzipped and your website will be loading faster.

For Further Details, please visit http://www.beanyhost.com

Attachments:
Beanyhost_com_HTTP_request.jpg Beanyhost_com_HTTP_request.jpg
Beanyhost_com_HTTP_request_compressed.jpg Beanyhost_com_HTTP_request_compressed.jpg

 
Was this article helpful? yes / no
Article details
Article ID: 30
Category: Beanyhost.com
Date added: 2011-06-30 04:32:43
Views: 1214
Rating (Votes): Article rated 4.0/5.0 (39)

 
« Go back

2008 - 2018 © Beanybux.com. | Privacy | TOS | Banners | Hosting | Forums | Blog | SEO | Q&A | Reseller