我想学fopen的用法,写了个程序,可没按我预想的打开http://www.php.net 这个网站呢??? 当然没有显示了你可以这样<?$fp = fopen("http://www.php.net", "r");echo fread($fp,10000);fclose($fp);?> 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 <?php$fd = fopen("/tmp/myfile.txt", "r");while ($buffer = fgets($fd, 4096)) { echo $buffer;}fclose($fd);?> <?$fp = fopen("http://www.php.net", "r"); fpassthru($fp);?>这样是不是好一点。 <?php$web = "http://www.php.net";$fp = @fopen($web,"r");if(!$fp){echo "can't open the website <font color=red>$web</font>";exit;}while (!feof ($fp)) { $buffer=fgets($fp, 4096); $msg.=$buffer;}echo $msg;?> webbench 测试问题 网站出错,求解释两行代码 how to install libflashplayer.so folder? mysql + adodb 在unix下能用吗 请问下日期自动更新的代码怎么写? 这个SQL语句怎么写啊? 不明白Zend_Controller_Dispatcher_Token 求助?关于用php开发在线的象棋系统如何下手? 请问哪里有dw 建设php网站的教程下载呀? 急,在线等,如何连接和访问c:\a.mdb数据库,谢谢大侠们! 我这样写mail函数为什么不对 在做mysql查询时 需要列的一部分怎么做啊?
$fd = fopen("/tmp/myfile.txt", "r");
while ($buffer = fgets($fd, 4096)) {
echo $buffer;
}
fclose($fd);
?>
$fp = fopen("http://www.php.net", "r");
fpassthru($fp);
?>这样是不是好一点。
$web = "http://www.php.net";
$fp = @fopen($web,"r");
if(!$fp){echo "can't open the website <font color=red>$web</font>";exit;}
while (!feof ($fp)) {
$buffer=fgets($fp, 4096);
$msg.=$buffer;
}
echo $msg;
?>