用户
 找回密码
 入住 CI 中国社区
搜索
查看: 3842|回复: 0
收起左侧

[HELP] nginx rewrite

[复制链接]
发表于 2009-12-28 12:25:51 | 显示全部楼层 |阅读模式
rewrite rule
location / {
             index index.php;
             #root /opt/lnmp/nginx/html/dogwin;
             if (-f $request_filename){
                  expires 3d;
                  access_log off;
             }
             if ($request_filename !~ (js|css|images|imgs|robots\.txt|index\.php)){
                  rewrite ^/(.+)$ /index.php/$1 last;
         #          rewrite . index.php last;
             }
        location ~ /index.php/ {
                fastcgi_index   index.php;
                fastcgi_pass    127.0.0.1:9000;
                fastcgi_param   SCRIPT_FILENAME /opt/lnmp/nginx/html/dogwin/index.php;
                include fcgi.conf;
        }   

不好用,为什么?

本版积分规则