01 |
$ch = curl_init(); |
02 |
curl_setopt( $ch , CURLOPT_URL, $url ); |
03 |
//设置URL,可以放入curl_init参数中 |
04 |
curl_setopt( $ch , CURLOPT_USERAGENT, "Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/535.1 (KHTML, like Gecko) Chrome/14.0.835.202 Safari/535.1" ); |
05 |
//设置UA |
|