当前位置: 代码迷 >> PHP >> php Failed opening required 'xxx.php'(include_path='.C:\php5\pear'是什么情况,该怎么处理
  详细解决方案

php Failed opening required 'xxx.php'(include_path='.C:\php5\pear'是什么情况,该怎么处理

热度:1458   发布时间:2012-04-07 17:31:51.0
php Failed opening required 'xxx.php'(include_path='.;C:\php5\pear'是什么情况
做PHP的时候出现了这么一个问题,
我在admin文件夹下建了一个页面,
访问根目录下的一个类文件.
代码是这样的
function getHtmls()
{
require_once '../newmanager.php';
require_once '../TheCompanysInsert/conn/conn.php';
$sql="SELECT * FROM phpcms_category WHERE module = 'yp'";
$rs = mysql_query($sql);
$arr = array();
$i = 1;
while($result = mysql_fetch_array($rs))
{
$category = new _category();
$category->catid = $result["catid"];
$category->module = $result["module"];
$category->parentid = $result["parentid"];
$category->arrparentid = $result["arrparentid"];
$category->child = $result["child"];
$category->arrchildid = $result["arrchildid"];
$category->catname = $result["catname"];
$arr["id$i"] = $category;
$i++;
}
return form::_getHtmls($arr);
}
我用Zend Studio编辑的时候都可以按ctrl找到那个类.
路径是没有错的,
但是跑起来的时候
Warning: form::require_once(../newmanager.php) [function.form-require-once]: failed to open stream: No such file or directory in D:\Apache2.2\htdocs\phpcms_demo\include\form.class.php on line 488

Fatal error: form::require_once() [function.require]: Failed opening required '../newmanager.php' (include_path='.;C:\php5\pear') in D:\Apache2.2\htdocs\phpcms_demo\include\form.class.php on line 488
就提示这个错误,
我在同级目录下访问这个类都可以正常,
但是一旦更换路径之后访问就会出现这个问题..
那位大哥告诉下这个错误是什么引起的额..小弟先在这谢过了..

------解决方案--------------------

------解决方案--------------------

------解决方案--------------------

------解决方案--------------------

------解决方案--------------------
  相关解决方案