Updated .htaccess
This commit is contained in:
18
.htaccess
18
.htaccess
@@ -1,10 +1,12 @@
|
|||||||
RewriteEngine On
|
# mod_rewrite starts here
|
||||||
RewriteBase /
|
RewriteEngine on
|
||||||
|
|
||||||
# redirect html pages to the root domain
|
# Prevent directory listings
|
||||||
RewriteRule ^index\.html$ / [NC,R,L]
|
Options All -Indexes
|
||||||
|
|
||||||
# remove filename
|
|
||||||
RewriteCond %{REQUEST_FILENAME} !-f
|
# does not apply to existing directories, meaning that if the folder exists on the server then don't change anything and don't run the Rule!
|
||||||
RewriteRule ^([^\.]+)$ $1.php [NC,L]
|
|
||||||
RewriteRule ^([^\.]+)$ $1.html [NC,L]
|
RewriteCond %{REQEUSTED_FILENAME} !-d
|
||||||
|
RewriteCond %{REQUEST_FILENAME}\.html -f
|
||||||
|
RewriteRule ^(.*)$ $1.html [NC,L]
|
Reference in New Issue
Block a user