I found out why this is happening, check my answer
This is the only domain in which this happens, I run curl_multi on a bunch of URLs, this one returns from 404 http_code http://www.breakingnews.com
But when I find it in the browser, it is 200OK (it takes time to download) and does not even look like a redirect.
Does anyone know what? This is a common problem.
here var_dump:
["info"]=> array(22) { ["url"]=> string(27) "http://www.breakingnews.com" ["content_type"]=> string(24) "text/html; charset=utf-8" ["http_code"]=> int(404) ["header_size"]=> int(337) ["request_size"]=> int(128) ["filetime"]=> int(-1) ["ssl_verify_result"]=> int(0) ["redirect_count"]=> int(0) ["total_time"]=> float(1.152229) ["namelookup_time"]=> float(0.001261) ["connect_time"]=> float(0.020121) ["pretransfer_time"]=> float(0.020179) ["size_upload"]=> float(0) ["size_download"]=> float(9755) ["speed_download"]=> float(8466) ["speed_upload"]=> float(0) ["download_content_length"]=> float(-1) ["upload_content_length"]=> float(0) ["starttransfer_time"]=> float(1.133522) ["redirect_time"]=> float(0) ["certinfo"]=> array(0) { } ["redirect_url"]=> string(0) "" } ["error"]=> string(0) ""
UPDATE: This looks like a php error with curl_setopt ($ ch, CURLOPT_NOBODY, true);
https://bugs.php.net/bug.php?id=39611
EDIT: This is not a mistake.
source
share