hangshare/admin/master/web/.htaccess - Htaccess File

hangshare/admin/master/web/.htaccess

#AuthType Basic
#AuthName "Password Protected Area"
#AuthUserFile /etc/apache2/.htpassword
#Require valid-user

<IfModule mod_headers.c>
    RewriteCond "%{HTTP:Accept-encoding}" "gzip"
    RewriteCond "%{REQUEST_FILENAME}.gz" -s
    RewriteRule "^(.*).css" "$1.css.gz" [QSA]
    RewriteCond "%{HTTP:Accept-encoding}" "gzip"
    RewriteCond "%{REQUEST_FILENAME}.gz" -s
    RewriteRule "^(.*).js" "$1.js.gz" [QSA]
    RewriteRule ".css.gz$" "-" [T=text/css,E=no-gzip:1]
    RewriteRule ".js.gz$" "-" [T=text/javascript,E=no-gzip:1]
    <FilesMatch "(.js.gz|.css.gz)$">
      Header append Content-Encoding gzip
      Header append Vary Accept-Encoding
    </FilesMatch>
</IfModule>
<IfModule mod_expires.c>
    ExpiresActive On
    ExpiresByType image/jpg "access 1 year"
    ExpiresByType image/jpeg "access 1 year"
    ExpiresByType image/gif "access 1 year"
    ExpiresByType image/png "access 1 year"
    ExpiresByType text/css "access 15 days"
    ExpiresByType application/pdf "access 1 month"
    ExpiresByType text/x-javascript "access 1 month"
    ExpiresByType text/javascript "access 1 month"
    ExpiresByType image/x-icon "access 1 year"
    ExpiresDefault "access 8 days"
</IfModule>
<IfModule mod_deflate.c>
    AddOutputFilterByType DEFLATE text/html text/plain text/css application/json
    AddOutputFilterByType DEFLATE application/javascript
    AddOutputFilterByType DEFLATE text/xml application/xml text/x-component
    AddOutputFilterByType DEFLATE application/xhtml+xml application/rss+xml application/atom+xml
    AddOutputFilterByType DEFLATE image/x-icon image/svg+xml application/vnd.ms-fontobject application/x-font-ttf font/opentype
</Ifmodule>

AddDefaultCharset UTF-8
RewriteEngine on
#RewriteCond %{HTTP_HOST} !^www.
#RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . index.php

On Github License

Files

Download PDF of Htaccess file
DEFLATE, HTTP_HOST, no-gzip, REQUEST_FILENAME

Comments

Apache