emaesen/kagalakan/master/app/.htaccess
#SPA support: redirect any request that is not a file, directory or index to index.html
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !index
RewriteRule (.*) /index.html
#set caching on images
<IfModule mod_expires.c>
ExpiresActive On
<FilesMatch ".(jpg|jpeg|png|gif|svg)$">
ExpiresDefault "access plus 1 month"
</FilesMatch>
</IfModule>
# prevent direct image linking
SetEnvIfNoCase Referer "kagalakan.com" local_ref=1
SetEnvIf Referer "^$" local_ref=1
<FilesMatch ".(gif|jpg)">
Order Allow,Deny
Allow from env=local_ref
</FilesMatch>
####################
# GZIP COMPRESSION #
####################
#SetOutputFilter DEFLATE
#AddOutputFilterByType DEFLATE text/html text/css text/plain text/xml application/x-javascript application/x-httpd-php
#BrowserMatch ^Mozilla/4 gzip-only-text/html
#BrowserMatch ^Mozilla/4.0[678] no-gzip
#BrowserMatch bMSIE !no-gzip !gzip-only-text/html
#BrowserMatch bMSI[E] !no-gzip !gzip-only-text/html
#SetEnvIfNoCase Request_URI .(?:gif|jpe?g|png)$ no-gzip
#Header append Vary User-Agent env=!dont-vary
On Github License
Files