当前位置: 首页 > 图文教程 > 网络编程 > PHP > 动态网页PHP脚本中include文件报错解决方法

PHP
如何学习一个新的PHP框架
配置最新的PHP加MYSQL服务器
PHP原版HTML编码器溢出问题的解决
PHP-Javascript“返回上一页”无缓存问题
基于DB2及PHP的应用系统跨平台迁移详细步骤(一)
基于DB2及PHP的应用系统跨平台迁移详细步骤(二)
PHP Squid中可缓存的动态网页设计
PHP读取文件夹内有多少个文件
PHP Header用于页面跳转要注意的几个问题总结
一些使用频率比较高的PHP函数
PHP5.2下preg_replace函数的问题
PHP-Push技术实现刷新功能
PHP动态图像的创建
PHP中重新定向到另一个页面
在PHP中将图片存放ORACLE中
PHP开发大型Web应用浅析
PHP正则相关的几个preg函数
PHP开发中最常见的文件操作疑难解答
面向普通人加密 使用PHP应用程序保护数据
记录PHP网站开发几个好功能

动态网页PHP脚本中include文件报错解决方法


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-08-14   浏览: 77 ::
收藏到网摘: n/a

1. 出现“未找到文件“类似的错误时候,检查include文件的位置是否正确,下面引用php手册页面的原话:

Files for including are first looked in include_path relative to the current working directory and then in the directory of the current script. E.g. if your include_path is libraries, current working directory is /www/, you included include/a.php and there is include "b.php" in that file, b.php is first looked in /www/libraries/ and then in /www/include/. If filename begins with ./ or ../, it is looked only in include_path relative to the current working directory.
2. 当出现permission deny 类似错误的时候,按以下方法排除
a) 检测被包含的文件读权限是否打开
b) 检测被包含的文件路径上的每个目录的x权限是否打开,该权限决定了目录能否被浏览。