thinkphp5出现500错误怎么办

互联网 19-8-23

thinkphp5出现500错误,如下图所示:

相关推荐:《ThinkPHP教程》

require(): open_basedir restriction in effect. File(/home/wwwroot/pic/thinkphp/start.php) is not within  the allowed

解决方法:

1、我是lnmp1.4 php5.6,php.ini里面的open_basedir 是注释掉的。

2、查找到是fastcgi问题。

3、修改fastcgi的配置文件。

/usr/local/nginx/conf/fastcgi.conffastcgi_param PHP_ADMIN_VALUE "open_basedir=$document_root/:/tmp/:/proc/";

修改为

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

4、重启 service nginx restart。

以上就是thinkphp5出现500错误怎么办的详细内容,更多内容请关注技术你好其它相关文章!

来源链接:
免责声明:
1.资讯内容不构成投资建议,投资者应独立决策并自行承担风险
2.本文版权归属原作所有,仅代表作者本人观点,不代表本站的观点或立场
标签: 错误
上一篇:php获取远程图片并下载保存到本地的方法分析 下一篇:thinkphp如何导出word

相关资讯