我遇到了一个关键问题,即我的 PHP 5.3.0 的 WAMP 安装没有找到我的计算机中存在的文件。有人对这个有了解吗?可能是 PHP 错误?任何帮助将非常感激。
这是创建文件的变量:
$baseNewsUrl = "C:/reviews/reviews/$platform/$fullname";
这是获取内容的代码:
if(is_file($baseNewsUrl)){
$contents = file_get_contents($baseNewsUrl);
} else {
echo "File not found. " . "\r\n";
continue;
}
这是以下的输出$baseNewsUrl
: C:/reviews/reviews/GBA/r20107_GBA.htm 该文件确实存在。