Possible Duplicate:
including php file from another server with php为什么我得到1而不是所需的文件?
我想有我自己的错误的系统,而不是具有PHP错误,这样的例子,我需要从另一台服务器上的文件,并且该服务器目前无法使用
<?php
require 'http://example.com/file.php' or die ("that host is not available right now");
?>
而是我得到
Warning: require(1) [function.require]: failed to open stream: No such file or directory in C:\xampp\htdocs\index.php on line 5
Fatal error: require() [function.require]: Failed opening required '1' (include_path='.;C:\xampp\php\PEAR') in C:\xampp\htdocs\index.php on line 5
如果您不是'example.com'的管理员,这是一个非常糟糕的主意。 – Dennis
@Pablo不,这不是'require(1)'的原因。 '1'是这里的问题。 – deceze