I'm trying to fetch this image using cURL: http://images.egypt.souq.com/media/item/2013/02/27/49/97/32/8/item_L_4997328_1650476.jpg
Using this code:
public static function fetchUrl($url) {
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_TIMEOUT, 50);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$data = curl_exec($ch); //get curl response
curl_close($ch);
return $data;
}
this code is working with any image (that I tried at least) except for the above image, it returns false after consuming all the timeout's 50 seconds,
did anybody know why?