thinkPHP 5 lnmp 下 rewrite 方法

因为thinkphp 5 的index.php入口文件 默认是在public目录下,

将nginx 的vhost 文件做以下修改


root /home/wwwroot/dzcj/public;


location ~ /
        try_files $uri $uri/ /index.php?s=$uri&$args;



Warning: require(): open_basedir restriction in effect. File(/home/wwwroot/ is not within the allowed path(s): (/home/wwwroot/ in /home/wwwroot/ on line 38

Warning: require(/home/wwwroot/ failed to open stream: Operation not permitted in /home/wwwroot/ on line 38

Fatal error: require(): Failed opening required '/home/wwwroot/' (include_path='.:/usr/local/php/lib/php') in /home/wwwroot/ on line 38



未经允许不得转载:Free-Abc智能 » thinkPHP 5 lnmp 下 rewrite 方法
分享到: 更多 (0)