MultiViews automatic precompressed gzipping

Discussion in 'Apache Migration/Compatibility' started by Moofius, Mar 29, 2010.

  1. Moofius

    Moofius New Member

    I have a folder with two files: test.css and test.css.gz.

    Browser requests test.css
    Apache checks if browser can accept gzip compressed files
    Apache checks if a precompressed file exists:
    Apache serves the test.css.gz​
    Apache gzips test.css​
    Apache serves test.css ungzipped​

    I want to be able to do that in Litespeed.
    I have tried to do this with RewriteRules and stuff, the problem is that litespeed gives the wrong headers, instead of Content-Type text/css Content-Encoding gzip it gives Content-Type gzip. This might be my fault, but I have no idea how to fix this.
  2. mistwang

    mistwang LiteSpeed Staff

    No need to do that, LiteSpeed create gzip cache for static files, just let LiteSpeed do that automatically.
  3. Moofius

    Moofius New Member

    Well then, how DO I enable gzip compression with the static gzip cache from a .htaccess file?
    I have tested
    SetOutputFilter DEFLATE
    RewriteRule . - [E=no-gzip:1]
    mod_gzip_on Yes
    mod_gzip_item_include mime text/css​

    There is no information about enabling gzip in your wiki, and the search function in your documentation gives a 404.
  4. mistwang

    mistwang LiteSpeed Staff

    You can only disable gzip at directory level, not enable.
    gzip should be enabled at global level in LSWS web console.
  5. janewalker123

    janewalker123 New Member

    LSWS web console is the best option to gzip it. try it. and let me know
  6. adhp123

    adhp123 Member

    I don't think you're going to save much though; with modern web servers, the cost of compressing the content on the fly is negligible

Share This Page