baloyou 发表于 2012-3-16 10:28:11

急救:nginx + firefox rewrite报错

1、该问题仅出现在 firefox + 反向代理,其他浏览器没问题,不通过反向代理访问没问题

http://domain/index.php//index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/index.php/user

nginx:
server
{
    listen       80   default;
   # server_namedomain;
    server_name 112.125.53.146;
    index index.html index.htm index.php;
    root/data0/www/wealth;

    #limit_conn   crawler20;

# rewrite"^(.*)$" /index.php/$1;
include /data0/www/wealth/.htaccess;
location ~ ^(.+\.php)(.*)$ {
      root   /data0/www/wealth;
                fastcgi_index index.php;
                fastcgi_split_path_info ^(.+\.php)(.*)$;
                fastcgi_param   SCRIPT_FILENAME $document_root$fastcgi_script_name;
                fastcgi_param   PATH_INFO               $fastcgi_path_info;
                fastcgi_param   PATH_TRANSLATED $document_root$fastcgi_path_info;
                fastcgi_pass 127.0.0.1:9000;
                include fcgi.conf;
      }

    location ~ .*\.(gif|jpg|jpeg|png|bmp|swf)$
    {
      expires      30d;
    }

    location ~ .*\.(js|css)?$
    {
      expires      1h;
    }

    log_formatwealth'$remote_addr - $remote_user [$time_local] "$request" '
            '$status $body_bytes_sent "$http_referer" '
            '"$http_user_agent" $http_x_forwarded_for';
    access_log/data1/logs/wealth.loglinks;
}



if (!-e $request_filename){
rewrite ^(.+)$ /index.php/$1 last;
}


页: [1]
查看完整版本: 急救:nginx + firefox rewrite报错