I redirect the *.yanbao360.com to www.yanbao360.com use the configuration below.
[quote]
location / {
if ($host != 'www.yanbao360.com') {
rewrite ^(.*)$ http://www.yanbao360.com$1;
}
}
[/quote]
everything is ok except three case return 200 not 302
how to duplicate (nginx 0.8.x ~ 0.9.x)
[quote]telnet yanbao360.com 80[/quote]
then paste one of these text
GET / HTTP/1.1
Host: WWW.yanbao360.com
GET / HTTP/1.1
Host: www.yanbao360.com.
GET / HTTP/1.1
Host: WWW.yanbao360.com.
press enter twice, you will get nginx return 200 OK