Update vhost.conf
This commit is contained in:
10
vhost.conf
10
vhost.conf
@@ -1,15 +1,21 @@
|
|||||||
|
|
||||||
index index.html index.php;
|
index index.html index.php;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
|
|
||||||
|
if ($request_uri ~ ^/sites/(.*)$ ) {
|
||||||
|
return 301 /$1;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
if ($request_uri ~ ^/index(\.html)?$) {
|
if ($request_uri ~ ^/index(\.html)?$) {
|
||||||
return 301 /;
|
return 301 /;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if ($request_uri ~ ^/(.*)\.html$) {
|
if ($request_uri ~ ^/(.*)\.html$) {
|
||||||
return 301 /$1;
|
return 301 /$1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
try_files $uri $uri/ $uri.html /sites$uri /sites$uri.html /index.php?$query_string;
|
try_files $uri $uri/ $uri.html /sites$uri /sites$uri.html /index.php?$query_string;
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user