HOME 生活记录运维/编程
作者/来源:yixinu.com
栏目:运维/编程
日期:2014-07-02 05:04:01
server {
        listen       80;
        server_name  t.jeexue.com;

        #charset koi8-r;

        #access_log  logs/host.access.log  main;
		
		client_max_body_size 100m;

        location / {
            root   "D:/WorkFile/00000000000/USBWebserver 8.5/root/jeexue.com/newjx";
            index  index.php index.html index.htm;
			if (!-e $request_filename) {
				rewrite ^/(.*)$ /index.php/$1 last;
				break;
			}
        }
		
		
        error_page   500 502 503 504  /50x.html;
        location = /50x.html {
            root   html;
        }

        # pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
        #
        #location ~ .php$ {
		location ~ .+.php($|/) {
			set $script    $uri;
			set $path_info  "/";
			 if ($uri ~ "^(.+.php)(/.+)") {
				set $script     $1;
				set $path_info  $2;
			 }

            root           "D:/WorkFile/00000000000/USBWebserver 8.5/root/jeexue.com/newjx";
            fastcgi_pass   127.0.0.1:9000;
            #fastcgi_index  index.php;
			fastcgi_index  index.php?IF_REWRITE=1;
			fastcgi_param PATH_INFO $path_info;
            fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;
            include        fastcgi_params;
        }

        # deny access to .htaccess files, if Apache's document root
        # concurs with nginx's one
        #
        #location ~ /.ht {
        #    deny  all;
        #}
    }
分享到:

Copyright © 2013-2014 yixinu.com 湘ICP备14004402号

QQ:316686606  Email: 316686606@qq.com