thinkphp5支持nginx

1.500错误 ---开启php.ini 的display_error

修改fastcgi的配置文件 /usr/local/nginx/conf/fastcgi.conf

fastcgi_param PHP_ADMIN_VALUE "open_basedir=$document_root/:/tmp/:/proc/";

改成

fastcgi_param PHP_ADMIN_VALUE "open_basedir=$document_root/../:/tmp/:/proc/";

 

2.修改php.ini的函数

3.404错误

修改/usr/local/nginx/conf/nignx.conf

if (!-e $request_filename) {
rewrite ^/index.php(.*)$ /index.php?s=$1 last;
rewrite ^/(.*)$ /index.php?s=$1 last;
break;
}
    

修改/usr/local/nginx/conf/enable-php.conf

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

 

 http://192.168.174.145/admin/login/index.html

posted @ 2019-04-14 22:17  飘散的白乌云  阅读(365)  评论(0编辑  收藏  举报