Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

added redirect for trailing slashes

  • Loading branch information...
commit 4440dae2e8cde6c9cd831d1ea04c2eb5ffa9f184 1 parent bb00527
@freekrai authored
View
BIN  .DS_Store
Binary file not shown
View
BIN  engine/.DS_Store
Binary file not shown
View
12 engine/default.htaccess
@@ -4,13 +4,19 @@ AddOutputFilterByType DEFLATE text/html text/plain text/css text/javascript text
RewriteEngine On
-RewriteRule ^([^\.]*)$ - [T=text/html]
+RewriteCond %{REQUEST_FILENAME}.php -f
+RewriteCond %{REQUEST_URI} !/$
+RewriteRule (.*) $1\.php [L]
+RewriteCond %{REQUEST_FILENAME} !-d
+RewriteRule ^(.+)/$ /$1 [R=301,L]
+
+RewriteRule ^([^\.]*)$ - [T=text/html]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}.html -f
RewriteRule ^(.*)$ $1.html [QSA,L]
-ErrorDocument 404 /404.html
-ErrorDocument 500 /500.html
+ErrorDocument 404 /404
+ErrorDocument 500 /500
Please sign in to comment.
Something went wrong with that request. Please try again.