
这句是重点 (如果是lnmp.org 一键环境安装的服务器环境,会有enable-php-pathinfo.conf 这个文件)
include enable-php-pathinfo.conf;
此文没有从头到尾叙述,只是说明了在Linux环境里面怎么搭建tp5的nginx环境
location / {
if (!-e $request_filename) {
rewrite ^(.*)$ /index.php?s=$1 last;
break;
}
}
最后给tp5框架里面的两个文件夹设置读写权限
chmod -R 777 public
chmod -R 777 runtime
重启nginx服务
service nginx restart