问题是出现在了PHP.INI上面了 
原因是php.ini里设置了

open_basedir=/var/web/w0895/:/tmp:/usr/lib/php

这里加上相关的目录就可以了

解答:
其实open_basedir 这个是用来限制php的目录访问权限什么的,如果不在允许的范围内,php就不能访问。
这个 open_basedir 在 php.ini 里可以设定,也可以在 apache的httpd.conf 里面设定

PHP报错open_basedir restriction in effect的更多相关文章

  1. 解决 php 报错 open_basedir restriction in effect或者nginx提示No input file specified怎么办

    解决 php 报错 open_basedir restriction in effect或者nginx提示No input file specified怎么办 问题是出现在了PHP.INI上面了 ,原 ...

  2. 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. ...

  3. PHPExcel中open_basedir restriction in effect的解决方法

    用PHPExcel做导出execl的时候发现在本地没有问题,但是把网站传到租用的服务器的时候就报错,具体如下: Warning: realpath() [function.realpath]: ope ...

  4. php错误提示 open_basedir restriction in effect 解决

    <VirtualHost *:80> DocumentRoot "D:/www/4w_raaaa_com_2017" ServerName www.raaaa.com: ...

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

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

  6. 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 ...

  7. open_basedir restriction in effect,解决php引入文件权限问题 解决方法

    如下: 出现问题的原因: 查看问题描述以及资料,发现是php open_basedir 配置的问题,PHP不能引入其授权目录上级及其以上的文件: 一般情况下是不会出现这种问题的,之所以出现这个问题绝大 ...

  8. 使用宝塔配置laravel站点时,遇到open_basedir restriction in effect. 原因与解决方法

    今天一位朋友在linux服务器部署thinkphp5的时候PHP报了这个错误,如下: Warning: require(): open_basedir restriction in effect. F ...

  9. 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 ...

随机推荐

  1. javascript遍历json对象数据的方法

    JSON中,有两种结构:对象和数组,对象是没有length这个属性,而数组结构是有的,下面分别说下这两种结构之间的区别和遍历方式. 1.对象 一个对象以“{”开始,“}”结束.每个“key”后跟一“: ...

  2. Andrew and Taxi CodeForces - 1100E (思维,拓扑)

    大意: 给定有向图, 每条边有一个权值, 假设你有$x$个控制器, 那么可以将所有权值不超过$x$的边翻转, 求最少的控制器数, 使得翻转后图无环 先二分转为判定问题. 每次check删除能动的边, ...

  3. IOS UIApplication和AppDelegate 关系

    UIApplication.AppDelegate.委托等的关系?  什么是委托?为什么要有委托?委托在Iphone中的实现机制是怎样的? 一般来说,我们创建了一个Iphone项目,默认会有这个mai ...

  4. vim中将tab 设置成4个空格

    在.vimrc中添加以下代码后,重启vim即可实现按TAB产生4个空格:set ts=4  (注:ts是tabstop的缩写,设TAB宽4个空格)set expandtab 对于已保存的文件,可以使用 ...

  5. java垃圾回收期如何工作(编程思想)

    垃圾回收器如何工作: 在以前的程序语言中,在堆上分配对象的代价十分昂贵,因此读者会自然觉得对Java中所有对象(基本类型除外)都在堆上分配的方式也非常高昂.然而,垃圾回收期对提高对象的创建速度,却具有 ...

  6. Portability Flaw Locale Dependent Comparison

    Portability Flaw Locale Dependent Comparison [问题描述] 该问题涉及String的toUpperCase()方法.具体通过例子演示相关现象. public ...

  7. c/c++ socket函数详解

    c/c++ socket函数详解 注意: 使用socketAPI前,要先将相关链接库(Ws2_32.lib)加入链接,并使用WSAStartUp函数初始化.每个socket函数都可能失败(返回-1), ...

  8. ubuntu 11.04 old sources.list

    #deb cdrom:[Ubuntu 11.04 _Natty Narwhal_ - Release amd64 (20110427.1)]/ natty main restricted # See ...

  9. Oracle 通过dblink和job方式实现两个数据库表之间数据同步

    需求是需要将Database_A中的dev_test表中的数据同步到Database_B中的dev_test表中. 因为是通过Database_B去同步Database_A库中的数据,所以操作都建立在 ...

  10. NUnit使用

    NUnit是.net平台上使用得最为广泛的测试框架之一,本文将通过示例来描述NUnit的使用方法,并提供若干编写单元测试的建议和技巧,供单元测试的初学者参考. 继续下文之前,先来看看一个非常简单的测试 ...