解决方法:

在如下文件增加一项(如图所示)

在如下文件增加一项(如图所示):

#php文件采用fastcgi解析并设置参数
    location ~ \.php {
        try_files $uri = 404;
        
        fastcgi_index  /index.php;
        fastcgi_pass ********;
        
        #加载fastcgi.conf文件中的参数
        include fastcgi.conf;
        
        #设置有权限目录,fastcgi.conf中默认设置就是站点目录$document_root,如果要改变就需要重新赋值
        #phalcon举例
        #fastcgi_param PHP_ADMIN_VALUE "open_basedir=/www/wwwroot/xcx/zerg/:/data/tmp/php/upload/:/proc/";
    }

访问项目:

继续配置

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

圆满解决!!!!!!!!!!!!!!

参考文件:

http://blog.csdn.net/leiflyy/article/details/68063423

https://www.iamle.com/archives/1609.html

http://blog.csdn.net/slqgenius/article/details/52949191(主要解决参看的文件)

require(): open_basedir restriction in effect. File(/www/wwwroot/xcx/zerg/thinkphp/start.php) is not within the allowed path(s): (/www/wwwroot/xcx/zerg/public/:/tmp/:/proc/) in /www/wwwroot/xcx/zerg/p的更多相关文章

  1. thinkPHP5配置nginx环境无法打开(require(): open_basedir restriction in effect. File(/mnt/hgfs/root/tp5/thinkphp/start.php) is not within the allowed path(s)

    今天想把玩一下tp5,结果怎么都无法访问,每次都是报500错误,我把错误提示都打开看到下面的错误 require(): open_basedir restriction in effect. File ...

  2. Warning: require(): open_basedir restriction in effect. File(/www/wwwroot/../thinkphp/start.php) is not within the allowed path(s):

    Warning: require(): open_basedir restriction in effect. File(/www/wwwroot//../thinkphp/start.php) is ...

  3. require(): open_basedir restriction in effect. File

    新安装的 lnmp 环境,将项目放上报 require(): open_basedir restriction in effect. File 的错误! 错误日志显示,访问脚本不在 open_base ...

  4. php Warning: require(): open_basedir restriction in effect File(/www/wwwroot/default/

    解决方案如下: 一.找到修改fastcgi的配置文件 (/usr/local/nginx/conf/fastcgi.conf) 二.vi进行编辑(保存退出) 三.对虚拟主机配置进行重写在Nginx低版 ...

  5. require(): open_basedir restriction in effect. 解决方法

    在linux服务器部署thinkphp5的时候PHP报了这个错误, 如下: Warning: require(): open_basedir restriction in effect. File(/ ...

  6. LNMP - Warning: require(): open_basedir restriction in effect错误解决方法

    LNMP 1.4或更高版本如果不想用防跨目录或者修改.user.ini的防跨目录的目录还需要将 /usr/local/nginx/conf/fastcgi.conf 里面的fastcgi_param ...

  7. open_basedir restriction in effect. File() is not within the allowed path(s)

    目前发现eaccelerator安装之后如果php.ini中设置open_basedir将导致open_basedir的一些报错(open_basedir restriction in effect. ...

  8. php 环境require(): open_basedir restriction in effect 错误

    php 环境require(): open_basedir restriction in effect 错误 错误日志显示,访问脚本不在 open_basedir的限定目录里面 解决方法打开fastc ...

  9. lnmp 环境require(): open_basedir restriction in effect 错误

    最近配置开发用的lnmp环境,环境配置完成后,爆500错误,查看nginx错误日志 open_basedir 将 PHP 所能打开的文件限制在指定的目录树,包括文件本身 错误日志显示,访问脚本不在 o ...

随机推荐

  1. UniGUI 之UniDBGrid(05)

    UniGUI 之UniDBGrid(05) 目录1]DataSource设置2]显示MEMO类型里的文字3]显示悬浮提示4]显示当前记录及总记录数5]读取所有记录,及分页6]在前面加上序号列7]不显示 ...

  2. Mini_Linux需要搭的环境

    1.bash:ifconfig:command not found sudo yum install -y net-tools 2.如果Linux系统是通过复制得到  需要更改hostname vi ...

  3. Android问题:ScrollView默认位置不是最顶部最全解决方案

    描述: Scrollview里面嵌套了一个listview ,这是开发中最寻常的一种布局,遇到的问题是:在这个Scrollview页面默认的起始位置不是最顶部,而是listview的底部. 原因: 在 ...

  4. pug

    https://github.com/pugjs/pug pug模板使用https://www.cnblogs.com/gudi/p/8080736.html

  5. 一个自己实现的Vector(只能处理基本类型数据)

    一个自己实现的Vector(只能处理基本类型数据) string 类型不行 bool char* int double float long long 等基本s类型可用 使用模板类实现.底层为数组实现 ...

  6. Core data 如何查看ObjectId

    ObjectId是Core Data 为每一个数据对象提供的唯一ID标识,获取ObjectID.并打印的方法如下: 步骤: 1. 获取ManagedObject 2. ManagedObject -& ...

  7. Spring Boot 学习(一)

    转载资料 spring boot快速入门 https://www.cnblogs.com/wmyskxz/p/9010832.html spring boot 入门篇 https://www.cnbl ...

  8. 几款Java模板引擎的性能评测

    参评的几款模板引擎为:XMLTemplate(简称XT)Velocity(简称VT)CommonTemplate(简称CT)FreeMarker(简称FT)Smarty4j(简称ST)直接的java代 ...

  9. 加拿大Assignment写作如何靠第一句话来吸睛?

    最近有留学加拿大的同学咨询我们如何写好assignment的首句,关于话题背景的引入,如何才能自然精妙,让老师对后文充满期待.小编用一句话总结今天的策略:陈述一个跟话题直接相关的事实.“直接相关”,保 ...

  10. 继OpenJDK 之后,OpenJFX也将迁移到 Git

    导读 近日 OpenJFX 项目负责人 Kevin Rushforth 提交了一份将 OpenJFX 迁移到 GitHub 的提案. OpenJFX 是 JavaFX 的开源实现.JavaFX 是一个 ...