Answer the question
In order to leave comments, you need to log in
Why does Location in location claim that its parameter is outside the parent folder?
server {
listen 80;
server_name localhost.dev;
location /89262207055 {
root /89262207055/;
location /file {
alias index.php?id=file&name=;
}
rewrite ^(.*).html$ index.php?id=block&block=$1;
}
}
Answer the question
In order to leave comments, you need to log in
location only tells the server which block of commands to execute, but does not change the environment. those. if you do it like this:
location /ololo {
root ololo1;
}
First of all:
you can't:
location /a/ {
location /b/ {
bla;
}
}
location /a/ {
location /a/b/ {
bla;
}
}
. server {
listen 80;
server_name localhost.dev;
rewrite ^(.*).html$ index.php?id=block&block=$1 last;
location /89262207055 {
root /89262207055/;
}
location /89262207055/file {
rewrite ^ /index.php?id=file&name= last;
}
location /index.php {
bla;
}
}
I suspect that the nested location is not relative to the main one
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question