我真的很难过这个。 我按照说明进行操作 http://code.google.com/apis/gdata/articles/php_client_lib.html#php-path-installation PHP安装检查器(可以在链接页面上找到)给我一个错误,包含dir错误,所以我试着确定这不是问题。
这就是我的目录:
[...]/httpdocs/include/library/Zend# ls
Exception.php Gdata Gdata.php Http Loader.php Registry.php Uri Uri.php Validate Version.php test.php
如你所见,我的test.php和Loader.php在同一个文件夹中。
[...]httpdocs/include/library/Zend# cat test.php
<?php
require_once("Loader.php");
echo "ok";
?>
我的error.log中出现了这个错误:
PHP Fatal error: require_once(): Failed opening required 'Loader.php' (include_path='.:') in /var/www/vhosts/[domain]/httpdocs/include/library/Zend/test.php on line 2
我也试过设置一个绝对包含路径:
[...]httpdocs/include/library/Zend# cat test.php
<?php
$clientLibraryPath = '/var/www/vhosts/[domain]/httpdocs/include/library/Zend';
$oldPath = set_include_path(get_include_path() . $clientLibraryPath);
echo get_include_path();
require_once("Loader.php");
?>
它确实回显。:/ var / www / vhosts / [domain] / httpdocs / include / library / Zend 但又一次:
PHP Fatal error: require_once(): Failed opening required 'Loader.php' (include_path='.:/var/www/vhosts/[domain]/httpdocs/include/library/Zend') in /var/www/vhosts/[domain]/httpdocs/include/library/Zend/test.php on line 6
来自phpinfo()的一些信息:
PHP API => 20090626
PHP Extension => 20090626
Zend Extension => 220090626
Zend Extension Build => API220090626,NTS
PHP Extension Build => API20090626,NTS
PHP Version => 5.3.2-1ubuntu4.14
我真的希望你们能帮助我......这让我发疯了
答案 0 :(得分:0)
安装调试扩展xdebug之后,我发现我上传的文件是由另一个用户和用户组拥有的,这就是为什么我的test.php(root:root)不允许访问Loader.php(sis:pcacln) chown sis:pcacln test.php 帮助了很多