Grow your CSS skills. Land your dream job.

Website Loading Time G_ZIP Compression

  • # November 22, 2009 at 7:10 pm

    Hello,
    I am having problems trying to use Gzip on my server.
    I would like to combine all my javascript files into one to help with load time.
    I went ahead and downloaded Gzip and uploaded to my server.
    I checked to see if my server enables gzip and zlib and it does.
    I then added:

    Code:
    php_flag zlib.output_compression On

    to my .htaccess file,
    which I found directions for here:http://blog.jc21.com/2007-02-08/how-to-use-gzip-to-load-your-site-faster/
    When I did that I get an internal server error.
    I called my hosting company and she said that php_flag zlib.output_compression On is the wrong syntax.
    She didn’t really sound like she knew what she was talking about though.
    Can anyone help me with how to do this?

    I also found this code:

    Code:

    mod_gzip_on Yes
    mod_gzip_dechunk Yes
    mod_gzip_item_include file .(html?|txt|css|js|php|pl|jpg|png|gif)$
    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.*

    that can be added to my.htaccess file and seems to be pretty straight forward, but It looks for mod_gzip.c on my server and I do not have that anywhere(I looked in the Gzip files that I have uploaded to my server). When added to my .htaccess file, I get no errors, so I would love to use this if I had that mod_gzip.c
    I’m on a linux server with PHP Version 5.2.11.

Viewing 1 post (of 1 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".