nagiro/Entrades/master/.htaccess - Htaccess File

nagiro/Entrades/master/.htaccess

Options -Indexes

<IfModule mod_rewrite.c>

  RewriteEngine On
  RewriteBase /

  RewriteCond %{HTTP:X-Forwarded-Proto} !https
  RewriteCond %{REQUEST_URI} !^/entrades/getTPV$
  RewriteCond %{REQUEST_URI} !index.php
  RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1 [R=301,L]

  # Force to exclude the trailing slash
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteCond %{REQUEST_URI} (.*)/$
  RewriteRule ^(.+)/$ $1 [R=307,L]

  # Restrict php files direct access
  RewriteCond %{THE_REQUEST} ^.+? [^?]+.php[? ]
  RewriteRule .php$ - [F]

  # Allow any files or directories that exist to be displayed directly
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d

  RewriteRule ^(.*)$ index.php?$1 [QSA,L]

</IfModule>

On Github License

Files

Download PDF of Htaccess file
HTTP_HOST, REQUEST_FILENAME, REQUEST_URI, THE_REQUEST, X-Forwarded-Proto

Comments

Apache