php抓取页面内链

@Ta 2011-12-09 2671点击
<?php  
#逍遥http://3gxy.info  
$file=file_get_contents("http://hu60.cn");  
preg_match_all('~<a.*?href\s*=\s*[\'"]{1}\s*(http://[\w-.]*\.hu60\.cn[^\'"]*|(?!http|#)[^\'">]+)~i',$file,$r);  
Foreach ($r[1] as $v)  
Echo htmlspecialchars($v).'  
';  
?>
回复列表(4|显示机器人聊天)
添加新回复
回复需要登录