Skip to content

Instantly share code, notes, and snippets.

@jjrom
Last active November 24, 2023 02:45

Revisions

  1. jjrom renamed this gist Nov 13, 2014. 1 changed file with 0 additions and 0 deletions.
    File renamed without changes.
  2. jjrom created this gist Nov 13, 2014.
    9 changes: 9 additions & 0 deletions gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,9 @@
    Add this to apache configuration file (not in .htaccess !)

    <Location />
    SetOutputFilter DEFLATE
    SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png)$ no-gzip dont-vary
    SetEnvIfNoCase Request_URI \.(?:mp3|wav|wma|au|m4p|snd|mid|wmv|mpg|mpeg|mp4|qt|mov)$ no-gzip dont-vary
    SetEnvIfNoCase Request_URI \.pdf$ no-gzip dont-vary
    SetEnvIfNoCase Request_URI \.(?:exe|t?gz|zip|gz2|sit|rar)$ no-gzip dont-vary
    </Location>