How to put a website, if it doesn't open after a GET request?

Hello, experts. Perhaps even the question is incorrect - please excuse me, I ask to the best of their knowledge.

Have a link: https://coinmarketcap.com/currencies/ripple/histor...
If parsim this link - everything is OK, the content freely receive.

Have a link: https://coinmarketcap.com/currencies/ripple/histor...
Parsim her boss, all is lost!
Return only the headers:
HTTP/1.1 200 OK
Date: Sat, 09 Dec 2017 20:46:28 GMT
Content-Type: text/html; charset=utf-8
Transfer-Encoding: chunked
Connection: keep-alive
Set-Cookie: __cfduid=d8e678f8b85d743e319149482103afb421512852387; expires=Sun, 09-Dec-18 20:46:27 GMT; path=/; domain=.coinmarketcap.com; HttpOnly; Secure
CF-Cache-Status: EXPIRED
Server: cloudflare-nginx
CF-RAY: 3caad05fad0a83ee-KBP


Please tell us how to put the second link. Three hours of searching on Google gave no results...

Configure cUrl with the following:
curl_setopt($ch, CURLOPT_URL, $url);
 curl_setopt($ch, CURLOPT_HEADER, 1);
 curl_setopt($ch, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/62.0.3202.94 Safari/537.36");
 curl_setopt($ch, CURLOPT_REFERER, $referer);
 curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
 curl_setopt($ch, THIS, false);
 curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false);
June 10th 19 at 16:21
3 answers
June 10th 19 at 16:23
Solution
Well, first what do you mean "all is lost"? What data You get back??
And second, it bots the site is protected with cloudflare and to check can give here is (to me at the second link given), your parser of course such a test does not pass.
5a2c49ee302e2184789178.jpeg
well this is most likely due to the fact that the obtained data is not found it necessary (by the way ought this moment normally handle and give a clear message), and curl that gives it? I suspect just the page with the captcha - alia98 commented on June 10th 19 at 16:26
Perhaps it is my parser does not pass protection. How to be in this case? There are options? - Roman_Fadel84 commented on June 10th 19 at 16:29
after the following code:
$html = curl_get('https://coinmarketcap.com/currencies/ripple/historical-data/?start=20130428&end=20171209');
 $dom = str_get_html($html);
 echo "
";
 print_r($html);

get the answer:
HTTP/1.1 200 OK
Date: Sat, 09 Dec 2017 20:46:28 GMT
Content-Type: text/html; charset=utf-8
Transfer-Encoding: chunked
Connection: keep-alive
Set-Cookie: __cfduid=d8e678f8b85d743e319149482103afb421512852387; expires=Sun, 09-Dec-18 20:46:27 GMT; path=/; domain=.coinmarketcap.com; HttpOnly; Secure
CF-Cache-Status: EXPIRED
Server: cloudflare-nginx
CF-RAY: 3caad05fad0a83ee-KBP
- Roman_Fadel84 commented on June 10th 19 at 16:32
June 10th 19 at 16:25
Parsim her boss, all is lost!


The problem is what?
Sorry, updated post. - alia98 commented on June 10th 19 at 16:28
I still do not understand...
the length of the response is what? in the body of the response to that?
the response code is normal, 200. - Roman_Fadel84 commented on June 10th 19 at 16:31
June 10th 19 at 16:27
what does not work?

https://coinmarketcap.com/api/
What in the API yet Historical Data, which I need to parse - alia98 commented on June 10th 19 at 16:30
Historical data CoinCap and CryptoCompare - Roman_Fadel84 commented on June 10th 19 at 16:33

Find more questions by tags PHPParsing