php数据通信方式
一:curl
$ch = curl_init();
curl_setopt($ch,CURLOPT_SSL_VERIFYPEER,false);
curl_setopt($ch,CURLOPT_TIMEOUT,$second);
curl_setopt($ch,CURLOPT_RETURNTRANSFER,1);
curl_setopt($ch,CURLOPT_URL,$url);
。。。
$data = curl_exec($ch);
curl_close($ch);
二:fsockopen
$fp = @fsockopen('www.belie8.com',80,$errno,$errstr,$timeout);
@fputs($fp,"GET /s?wd=... HTTP/1.1\r\nHost:www.belie8.com\r\nConnection:Close\r\n");
while($fp && !feof($fp))
$data .=fread($fp,1024)
@fclose($fp);
三:file_get_contents 采集
$files = @file_get_contents( "http://www.beie8.com/belie8.txt" );
$arr = explode( "\n", $files );
$arr = array_reverse($arr);
没有这么多结果。简简单单,走好每一步路----belie8