xujun389 发表于 2013-01-22 23:29

nginx 跳转的问题

默认是index.html网页
现在当我们在浏览器中输入http://www.abc.com/index.html 就跳转到http://www.abc.com/这个页面上来
试了几个规则都不行如下:
1.location ~ ^/index\.html$ {
if (-e $request_filename){
rewrite ^/(.*)$ http://www.ilaw360.com last;
break;
}


2.location ~ ^/index\.html$ {
rewrite ^/(.*)$ http://www.ilaw360.com last;
}   提示过多的重定向
求方法

3.rewrite ^/(.*)$ http://www.ilaw360.com last;

xujun389 发表于 2013-01-22 23:30

3.rewrite ^/(index.html)$ http://www.ilaw360.com last;   这是第三个
页: [1]
查看完整版本: nginx 跳转的问题