• Resolved jidwictut9

    (@jidwictut9)


    Hello,

    is it possible to disable gzip compression (my server uses Brotli)?
    The plugin writes the following in the .htaccess:

    # BEGIN WP-Optimize Gzip compression
    <IfModule mod_filter.c>
    <IfModule mod_deflate.c>
    # Compress HTML, CSS, JavaScript, text, XML and fonts
    AddType application/vnd.ms-fontobject .eot
    AddType font/ttf .ttf
    AddType font/otf .otf
    AddType font/x-woff .woff
    AddType image/svg+xml .svg

    AddOutputFilterByType DEFLATE application/javascript
    AddOutputFilterByType DEFLATE application/rss+xml
    AddOutputFilterByType DEFLATE application/vnd.ms-fontobject
    AddOutputFilterByType DEFLATE application/x-font
    AddOutputFilterByType DEFLATE application/x-font-opentype
    AddOutputFilterByType DEFLATE application/x-font-otf
    AddOutputFilterByType DEFLATE application/x-font-truetype
    AddOutputFilterByType DEFLATE application/x-font-ttf
    AddOutputFilterByType DEFLATE application/x-font-woff
    AddOutputFilterByType DEFLATE application/x-javascript
    AddOutputFilterByType DEFLATE application/xhtml+xml
    AddOutputFilterByType DEFLATE application/xml
    AddOutputFilterByType DEFLATE font/opentype
    AddOutputFilterByType DEFLATE font/otf
    AddOutputFilterByType DEFLATE font/ttf
    AddOutputFilterByType DEFLATE font/off
    AddOutputFilterByType DEFLATE image/svg+xml
    AddOutputFilterByType DEFLATE image/x-icon
    AddOutputFilterByType DEFLATE text/css
    AddOutputFilterByType DEFLATE text/html
    AddOutputFilterByType DEFLATE text/javascript
    AddOutputFilterByType DEFLATE text/plain
    AddOutputFilterByType DEFLATE text/xml

    # Remove browser bugs (required only for very old browsers)
    BrowserMatch ^Mozilla/4 gzip-only-text/html
    BrowserMatch ^Mozilla/4\.0[678] no-gzip
    BrowserMatch \bMSIE !no-gzip !gzip-only-text/html
    <IfModule mod_headers.c>
    Append header Vary user agent
    </IfModule>
    </IfModule>
    </IfModule>
    # END WP-Optimize Gzip compression

    How to turn this off?

    • This topic was modified 2 years, 2 months ago by jidwictut9.
    • This topic was modified 2 years, 2 months ago by jidwictut9.
Viewing 2 replies - 1 through 2 (of 2 total)
  • @jidwictut9 To disable GZIP you can remove the following lines from .htaccess file:

    # BEGIN WP-Optimize Gzip compression
    <IfModule mod_filter.c>
    <IfModule mod_deflate.c>
    # Compress HTML, CSS, JavaScript, text, XML and fonts
    AddType application/vnd.ms-fontobject .eot
    AddType font/ttf .ttf
    AddType font/otf .otf
    AddType font/x-woff .woff
    AddType image/svg+xml .svg
    
    AddOutputFilterByType DEFLATE application/javascript
    AddOutputFilterByType DEFLATE application/rss+xml
    AddOutputFilterByType DEFLATE application/vnd.ms-fontobject
    AddOutputFilterByType DEFLATE application/x-font
    AddOutputFilterByType DEFLATE application/x-font-opentype
    AddOutputFilterByType DEFLATE application/x-font-otf
    AddOutputFilterByType DEFLATE application/x-font-truetype
    AddOutputFilterByType DEFLATE application/x-font-ttf
    AddOutputFilterByType DEFLATE application/x-font-woff
    AddOutputFilterByType DEFLATE application/x-javascript
    AddOutputFilterByType DEFLATE application/xhtml+xml
    AddOutputFilterByType DEFLATE application/xml
    AddOutputFilterByType DEFLATE font/opentype
    AddOutputFilterByType DEFLATE font/otf
    AddOutputFilterByType DEFLATE font/ttf
    AddOutputFilterByType DEFLATE font/off
    AddOutputFilterByType DEFLATE image/svg+xml
    AddOutputFilterByType DEFLATE image/x-icon
    AddOutputFilterByType DEFLATE text/css
    AddOutputFilterByType DEFLATE text/html
    AddOutputFilterByType DEFLATE text/javascript
    AddOutputFilterByType DEFLATE text/plain
    AddOutputFilterByType DEFLATE text/xml
    
    # Remove browser bugs (required only for very old browsers)
    BrowserMatch ^Mozilla/4 gzip-only-text/html
    BrowserMatch ^Mozilla/4\.0[678] no-gzip
    BrowserMatch \bMSIE !no-gzip !gzip-only-text/html
    <IfModule mod_headers.c>
    Append header Vary user agent
    </IfModule>
    </IfModule>
    </IfModule>
    # END WP-Optimize Gzip compression
    Plugin Contributor Venkat Raj

    (@webulous)

    Hi @jidwictut9

    I believe your development server used gzip and WPO wrote the .htaccess rules.
    Later, when you moved to production server or enabled brotli module, the .htaccess rules weren’t removed.

    We have applied a fix for this issue and it will be available in the next release. So, I’m marking this thread as Resolved

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Disable Gzip Compression / Writing .htaccess’ is closed to new replies.