merge-requests/2/head
Matthew 2021-07-08 23:58:13 -04:00
parent 14b18150a2
commit 2f79e5ca9a
No known key found for this signature in database
GPG Key ID: 210AF32ADE3B5C4B
1 changed files with 1 additions and 21 deletions

View File

@ -15,30 +15,10 @@ server {
index index.html index.htm index.php;
charset utf-8;
# Remove index.php$
if ($request_uri ~* "^(.*/)index\.php$") {
return 301 $1;
}
location / {
try_files $uri $uri/ /index.php?$query_string;
# Remove from everywhere index.php
if ($request_uri ~* "^(.*/)index\.php(/?)(.*)") {
return 301 $1$3;
}
}
# Remove trailing slash.
if (!-d $request_filename) {
rewrite ^/(.+)/$ /$1 permanent;
}
# Clean Double Slashes
if ($request_uri ~* "\/\/") {
rewrite ^/(.*) /$1 permanent;
}
error_page 404 /index.php;