Htaccess File

the-ms/engine/master/web/.htaccess

DEFLATE, HTTP_HOST, REQUEST_FILENAME
Options All -ExecCGI -Indexes -Includes +FollowSymLinks
ServerSignature Off
IndexIgnore */*
DirectoryIndex index.php
AddDefaultCharset utf-8

#RemoveHandler .html .htm
#AddHandler application/x-httpd-php .html
AddType application/x-javascript .js
AddType text/css .css
AddType text/xml .xml
AddType application/octet-stream .doc .mov .avi .pdf .xls
AddType text/x-component .htc

#Redirect / http://site.com

<IfModule mod_rewrite.c>
  #Options -Indexes
  RewriteEngine on
  RewriteBase /

  #Remove www
    RewriteCond %{HTTP_HOST} ^www.(.+)$ [NC]
    RewriteRule ^(.*) http://%1/$1 [L,R=301]

  #Under construction mode
  #RewriteCond %{REQUEST_FILENAME} !(works.html)
  #RewriteRule .* works.html

    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)/$ /$1 [L,R=301]

    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . index.php
</IfModule>
<ifModule mod_php.c>
  php_value  upload_max_filesize  8M
  php_value  post_max_size 2M
  php_value  default_charset utf-8
  php_value  max_execution_time 200
</ifModule>
<ifModule mod_deflate.c>
  AddOutputFilterByType DEFLATE text/html text/plain text/xml application/xml application/xhtml+xml text/css text/javascript application/javascript application/x-javascript
</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 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>

#ErrorDocument 404 /404/

#php_flag display_errors On
Exit mobile version