Do nginx do not auto differentiate the file name and directory name in the url?

Igor Sysoev igor at sysoev.ru
Tue Mar 2 17:56:32 MSK 2010


On Mon, Mar 01, 2010 at 09:29:35PM -0500, ultrawind wrote:

> hello,Vicente Aguilar,
> thank you for your helping.I found the point by the LiveHTTPHeaders Firefox plugin  .
> i set the server_name localhost to 192.168.1.124;Then it's work now.
> 

You should either set "server_name_in_redirect off" or set server_name
to the requested domain name.

> this is the result:
> http://192.168.1.124/myweb
> 
> GET /homekoo.com HTTP/1.1
> Host: 192.168.1.124
> User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; zh-CN; rv:1.9.2) Gecko/20100115 Firefox/3.6
> Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
> Accept-Language: zh-cn,zh;q=0.5
> Accept-Encoding: gzip,deflate
> Accept-Charset: GB2312,utf-8;q=0.7,*;q=0.7
> Keep-Alive: 115
> Connection: keep-alive
> Cookie: visit_level=2; db_=idsYt7hyLPjGct%2Bh8MfNpErRnk2t9T9D6Vf4iJ4; others=2NkY5OwkK6n%2FSYfB8Ao; rtime=4; ltime=1267496256399; cnzz_eid=39895488-1264743989-; __utma=81186391.1499015929.1265772641.1267411366.1267496256.3; __utmz=81186391.1265772641.1.1.utmccn=(direct)|utmcsr=(direct)|utmcmd=(none); Hm_lvt_7cb1f2f2baf6ab2ae929ad8cb88d6210=1265772641278; cnzz_a485651=0; sin485651=; cnzz_a977997=0; sin977997=; cnzz_a1366560=0; sin1366560=; __utmb=81186391; __utmc=81186391; _SID=6e46d49d85cf0da3b88eac61b6a3edd1
> 
> HTTP/1.1 301 Moved Permanently
> Server: nginx
> Date: Tue, 02 Mar 2010 02:16:21 GMT
> Content-Type: text/html
> Content-Length: 178
> Location: http://localhost/myweb/
> Connection: keep-alive
> ----------------------------------------------------------
> 
> Posted at Nginx Forum: http://forum.nginx.org/read.php?2,57890,58862#msg-58862
> 
> 
> _______________________________________________
> nginx mailing list
> nginx at nginx.org
> http://nginx.org/mailman/listinfo/nginx

-- 
Igor Sysoev
http://sysoev.ru/en/



More information about the nginx mailing list