updated
This commit is contained in:
parent
df79bd83c0
commit
673cbfb21c
6
htaccess
6
htaccess
@ -1,6 +1,10 @@
|
||||
RewriteEngine On
|
||||
|
||||
# Remove .php extension from URLs
|
||||
# Redirect requests for .php files to the same URL without .php
|
||||
RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /([^.]+)\.php [NC]
|
||||
RewriteRule ^ /%1 [L,R=301]
|
||||
|
||||
# Internally rewrite requests without .php to the actual .php file
|
||||
RewriteCond %{REQUEST_FILENAME} !-d
|
||||
RewriteCond %{REQUEST_FILENAME}\.php -f
|
||||
RewriteRule ^(.+)$ $1.php [L]
|
||||
Loading…
Reference in New Issue
Block a user