$curl = curl_init($feedurl);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, TRUE);
curl_setopt($curl, CURLOPT_HEADER, TRUE);
curl_setopt($curl, CURLOPT_ENCODING, "gzip,deflate");
$xml = curl_exec($curl);
var_dump(curl_getinfo($curl, CURLINFO_SIZE_DOWNLOAD));
// Check if any error occurred
if(!curl_errno($curl)) {
$info = curl_getinfo($curl);
echo 'Took ' , $info['total_time'] , ' seconds to send a request to ' , $info['url'] , "</BR>";
}
else {
echo "There was some sort of error." , "/<BR>";
}
curl_close($curl);
$xmlStr = file_get_contents("$feedurl") or die("can't get file");