tungpham42/biorhythm/master/.htaccess - Htaccess File

tungpham42/biorhythm/master/.htaccess

# Protect files and directories from prying eyes.
<FilesMatch ".(admin|ads|app-icons|captcha|clickmap|clicktale|db|diendan|ebooks|images|img|includes|ip|livechat|luongcuc|min|mp3|new|power|proverbs|race|racer|templates|tic-tac-toe|triggers|uploads|workers|sh|.*sql|theme|tpl(.php)?|xtmpl)(~|.sw[op]|.bak|.orig|.save)?$|^(..*|Entries.*|Repository|Root|Tag|Template)$|^#.*#$|.php(~|.sw[op]|.bak|.orig.save)$">
  Order allow,deny
</FilesMatch>
<Files ~ ".db$">
  Deny from all
</Files>
# Don't show directory listings for URLs which map to a directory.
Options -Indexes

# Follow symbolic links in this directory.
Options +FollowSymLinks

Options -MultiViews

AddType application/x-web-app-manifest+json .webapp
AddHandler x-web-app-manifest+json .webapp
AddType text/cache-manifest .appcache

AddType video/ogg .ogv
AddType video/mp4 .mp4
AddType video/webm .webm

## EXPIRES CACHING ##
<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 1 month"
  ExpiresByType text/html "access 1 month"
  ExpiresByType application/pdf "access 1 month"
  ExpiresByType text/x-javascript "access 1 month"
  ExpiresByType application/x-shockwave-flash "access 1 month"
  ExpiresByType image/x-icon "access 1 year"
  ExpiresDefault "access 1 month"
  ExpiresByType font/ttf "access plus 10 years"
  ExpiresByType font/otf "access plus 10 years"
  ExpiresByType application/vnd.ms-fontobject "access plus 10 years"
  ExpiresByType application/x-woff "access plus 10 years"
  ExpiresByType image/svg+xml "access plus 10 years"
</IfModule>
## EXPIRES CACHING ##
<IfModule mod_rewrite.c>
  RewriteEngine On
  RewriteBase /
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule ^sitemap.xml$ sitemap.php [L]
  RewriteRule ^fullname/([^/]*)/dob/([^/]*)$ /?fullname=$1&dob=$2 [L,QSA,PT,R=301]
  RewriteRule ^dob/([^/]*)$ /?dob=$1 [L,QSA,PT,R=301]
</IfModule>
<IfModule mod_headers.c>
  Header set Connection keep-alive
  <FilesMatch ".(ico|pdf|flv|jpg|jpeg|png|gif|js|css|swf|eot|woff|otf|ttf|svg)$">
    Header set Cache-Control "max-age=290304000, public"
  </FilesMatch>
</IfModule>
# BEGIN GZIP
AddOutputFilterByType DEFLATE text/plain
AddOutputFilterByType DEFLATE text/html
AddOutputFilterByType DEFLATE text/xml
AddOutputFilterByType DEFLATE text/css
AddOutputFilterByType DEFLATE application/xml
AddOutputFilterByType DEFLATE application/xhtml+xml
AddOutputFilterByType DEFLATE application/rss+xml
AddOutputFilterByType DEFLATE application/javascript
AddOutputFilterByType DEFLATE application/x-javascript
AddOutputFilterByType DEFLATE application/vnd.ms-fontobject
AddOutputFilterByType DEFLATE font/ttf
AddOutputFilterByType DEFLATE font/otf
AddOutputFilterByType DEFLATE image/svg+xml
<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>
# END GZIP

On Github License

Files

Download PDF of Htaccess file
DEFLATE, REQUEST_FILENAME

Comments

Apache