lnmp nginx 服务器怎么支持thinkphp3.2.2

浏览:1588 发布日期:2017/11/01 分类:求助交流 关键字: nginx thinkphp3.2.2 lnmp
我的配置文件这么写的


server {
listen 80;
server_name haix.admin671.com;
root /alidata/www/haix;
index index.html index.htm index.php;

server_name localhost;

location / {
try_files $uri $uri/ index.php;
}

location ~ ^.+\.php($|/) {
fastcgi_pass 127.0.0.1:9001;
fastcgi_index index.php;

if ($request_filename ~* (.*)\.php) {
set $php_url $1;
set $document_root$fastcgi_path_info $2;
}
if (!-f $php_url.php) {
return 404;
}

include fastcgi_params;

fastcgi_split_path_info ^((?U).+\.php)(/?.+)$;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param script_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;

}
}

最佳答案
评论( 相关
后面还有条评论,点击查看>>