Htaccess File

Schepp/CSS-JS-Booster/master/htaccess/.htaccess

DEFLATE, Pragma
#CSS-JS-Booster Start#################################################
#Turn ETagging off
Header unset Pragma
FileETag None
Header unset ETag

<FilesMatch "\.(js|css|html|htm|php|xml|)$">
SetOutputFilter DEFLATE
</FilesMatch>

#Turn ETagging on for Booster PHP files
<FilesMatch ".*booster_.+.php$">  
FileETag MTime Size

#Give access even if webmaster has globally forbidden access
Order deny,allow
Allow from all
Satisfy any
</FilesMatch>

#Force caching of some common files for some time in the browser's cache, to save bandwidth.
#"Mod_expires" needs to be installed in your Apache server, to use this feature.
<IfModule mod_expires.c>
  ExpiresActive On
  ExpiresDefault "access plus 1 minutes"
  ExpiresByType text/html "access plus 1 minutes"
  ExpiresByType text/css "access plus 35 days"
  ExpiresByType text/javascript "access plus 35 days"
  ExpiresByType text/plain "access plus 35 days"
  ExpiresByType application/x-javascript "access plus 35 days"
  ExpiresByType application/x-shockwave-flash "access plus 35 days"
  ExpiresByType image/gif "access plus 1 years"
  ExpiresByType image/jpeg "access plus 1 years"
  ExpiresByType image/jpg "access plus 1 years"
  ExpiresByType image/png "access plus 1 years"
  ExpiresByType image/x-icon "access plus 1 years"
</IfModule>

<IfModule mod_gzip.c>
mod_gzip_on Yes
mod_gzip_dechunk Yes
mod_gzip_item_include file .(html?|txt|css|js|php|pl)$
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>

#Alternative caching using Apache's "mod_headers", if it's installed.
#Caching of common files - ENABLED
<IfModule mod_headers.c>
<FilesMatch ".(ico|pdf|js|css|gif|png|jpg|jpeg|ico|txt|html|htm)$">
Header set Cache-Control "max-age=2592000, public"
</FilesMatch>
#Remove comments, to disable video caching to the user's browser
#<FilesMatch ".(flv|wmv|avi|mpg|3gp|rm|mpeg|mp4|qt|mov|divx|xvid|wmv|asf|dat|xml)$">
#Header set Cache-Control "max-age=0, public"
#</FilesMatch>
</IfModule>
#CSS-JS-Booster End#################################################
Exit mobile version