Hi.
I tried to rewrite all non-www url to www url, but when i tried to
access the site, i got the infinite loop. following is my config
server {
server_name www.example.com;
}
location / {
.......
rewrite ^ http://example.com$request_uri? permanent;
proxy_pass http://example.com
}
but if i change to redirect to the www url with locale(like, en, zh_CN),
it works fine. following is the config.
server {
server_name www.example.com;
}
location / {
.......
rewrite ^ http://example.com/zh_CN$request_uri? permanent;
}
location ^~ /zh_CN {
.........
proxy_pass http://example.com
}
any help is appreciated.
Thank You
Steve
--
Posted via http://www.ruby-forum.com/.
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx