codeigniter nginx配置

轉載:http://www.nginx.cn/1134.htmlphp

server{
        listen 80;
server_name www.ci.oa.com;
access_log /usr/local/services/nginx/logs/www.ci.oa.com.access.log;
error_log /usr/local/services/nginx/logs/www.ci.oa.com.error.log;
charset utf-8;
        location / {
root /home/test/project/www/CodeIgniter-3.0.3;
index index.php;
try_files $uri $uri/ /index.php?$uri&$args;
}
        location ~ ^.+.php {           include        fastcgi_params;           root /home/test/project/www/CodeIgniter-3.0.3;           fastcgi_pass   127.0.0.1:9000;           fastcgi_index  index.php;           fastcgi_split_path_info ^((?U).+.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_param CI_ENV      testing;  #.development/testing/production,ci的開發/測試/生產環境,用於$_SERVER['CI_ENV'])        }}
相關文章
相關標籤/搜索