包括“/目录/ filename.php"没有找到.包括“目录/ filename.php"发现.为


include "/directory/filename.php" not found. include "directory/filename.php" found. why?

include "/directory/filename.php"写入错误
include "directory/filename.php"找到它

我想升级我们的服务器硬件,我安装了apache/php/pgsql到新的服务器。

在旧的硬件上,第一个包含代码运行完美,所以我猜我的php.ini文件有问题。

我试图改变我的php.ini中的include_path,它没有效果

警告:include_once(/类/class_masterplan.php)(函数。:打开流失败:没有这样的文件或目录D:'PHP'work.php on line 218

警告:include_once() [function。include]:打开失败包含'/class/class_masterplan.php' (include_path='.;D:'php')in D:'PHP'work.php on line 218

致命错误:在D:'PHP'work.php中找不到Class 'masterplan'219

我想知道,什么服务器配置变量可能导致/解决这个问题

因为如果你使用了一个斜杠,应用程序会认为它是一个绝对路径,但它不是。如果省略斜杠,则使用的是相对路径。参见:http://webdesign.about.com/od/beginningtutorials/a/aa040502a.htm