amirmasoud/chakoshLaravelBlog/master/public/.htaccess - Htaccess File

amirmasoud/chakoshLaravelBlog/master/public/.htaccess

<IfModule mod_rewrite.c>
    <IfModule mod_negotiation.c>
        Options -MultiViews
    </IfModule>

    RewriteEngine On

    # Redirect Trailing Slashes If Not A Folder...
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)/$ /$1 [L,R=301]

    # Handle Front Controller...
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^ index.php [L]
</IfModule>

# BEGIN GZIP
<ifmodule mod_deflate.c>
    AddOutputFilterByType DEFLATE text/text text/html text/plain text/xml text/css application/x-javascript application/javascript
</ifmodule>
# END GZIP

# BROWSER CACHE EXPIRE
<IfModule mod_expires.c>
   ExpiresActive on
   ExpiresDefault "access plus 1 month"
   ExpiresByType application/javascript "access plus 1 year"
   ExpiresByType image/x-ico "access plus 1 year"
   ExpiresByType image/jpg "access plus 14 days"
   ExpiresByType image/jpeg "access plus 14 days"
   ExpiresByType image/gif "access plus 14 days"
   ExpiresByType image/png "access plus 14 days"
   ExpiresByType text/css "access plus 14 days"
</IfModule>

## SITE REFERRER BANNING
RewriteCond %{HTTP_REFERER} copyrightclaims.org [NC,OR]
RewriteCond %{HTTP_REFERER} copyrightclaims.org
RewriteRule .* - [F]

On Github License

Files

Download PDF of Htaccess file
CACHE, DEFLATE, HTTP_REFERER, REQUEST_FILENAME

Comments

Apache