Post by i2Paq » Sun Jan 13, 2013 9:36 pm

My hoster enabled gzip for me but now I have issues getting it to work.

After contacting them the adviced me to put the following code "somewhere" in php ???

Code: Select all

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

In my .htaccess I already have:

Code: Select all

<IfModule mod_gzip.c>
mod_gzip_on Yes
mod_gzip_dechunk Yes
mod_gzip_item_include file \.(html?|txt|css|js|php)$
mod_gzip_item_include handler ^cgi-script$
mod_gzip_item_include mime ^text/.*
mod_gzip_item_include mime ^application/x-javascript.*
mod_gzip_item_exclude mime ^image/.*
mod_gzip_item_exclude rspheader ^Content-Encoding:.*gzip.*
</IfModule> 
So after adding the code to php I should be up and running.

Norman in 't Veldt
Moderator OpenCart Forums

_________________ READ and Search BEFORE POSTING _________________

Our FREE search: Find your answer FAST!.

[How to] BTW + Verzend + betaal setup.


User avatar
Global Moderator

Posts

Joined
Mon Nov 09, 2009 7:00 pm
Location - Winkel - The Netherlands

Post by i2Paq » Tue Jan 15, 2013 12:58 am

No-one?

Norman in 't Veldt
Moderator OpenCart Forums

_________________ READ and Search BEFORE POSTING _________________

Our FREE search: Find your answer FAST!.

[How to] BTW + Verzend + betaal setup.


User avatar
Global Moderator

Posts

Joined
Mon Nov 09, 2009 7:00 pm
Location - Winkel - The Netherlands

Post by butte » Thu Aug 22, 2013 1:42 pm

I would guess, i2Paq, that you found a solution in those six months and f'got to mark it Solved, but maybe not.

From the gameplan to compress, putting that in header.php seems to make sense, perhaps above head or between head and body. Just a hunch, might even be right, dunno.

Guru Member

Posts

Joined
Wed Mar 20, 2013 6:58 am
Who is online

Users browsing this forum: No registered users and 11 guests