PHP用curl采集某个url出现400错误求解
<!--Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/-->$ch = curl_init(); curl_setopt($ch, CURLOPT_URL,$url); //curl_setopt($ch, CURLOPT_HEADER, false); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); //curl_setopt($ch, CURLOPT_TIMEOUT, 30); //curl_setopt($ch, CURLOPT_POST, 0); $data = curl_exec($ch); curl_close($ch); return $data;