With this rewrite everything works fine:
map $uri $new_uri {
default '';
~^/mysite(?<real_uri>.*)$ $real_uri;
}
and
if ($new_uri) {
return 301 $scheme://myserver$new_uri;
}
But what happens, that I want to redirect from "/site" folder to the root: "/"
I have already "/sites" directory and this rewrite transforms it to "s"
Ex: "mysite.com/sites" become "mysite.coms" because "mysite.com/site" redirects to "mysite.com"
It is possible to create a rewrite that will redirect from "/site: without touching "/sites" directory?
Thanks!
Edited 1 time(s). Last edit at 05/23/2012 09:07AM by sf1.