@ 2017-04-19T07:27:37Z <?php
$url = 'http://vnexpress.net/tin-tuc/phap-luat/15-canh-sat-bi-bat-giu-tai-my-duc-duoc-tha-tu-do-3571959.html';
echo $url."\n";
$ch = curl_init();
curl_setopt($ch,CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CONNECTTIMEOUT ,5); //timeout in seconds
curl_setopt($ch, CURLOPT_TIMEOUT, 5); //timeout in seconds
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
$result = curl_exec($ch);
if(curl_exec($ch) === false)
{
echo 'Curl error: ' . curl_error($ch);
}
else
{
var_dump($result);
}
Enable javascript to submit You have javascript disabled. You will not be able to edit any code.
Output for 7.0.0 - 7.0.20 , 7.1.0 - 7.1.20 , 7.2.0 - 7.2.33 , 7.3.16 - 7.3.33 , 7.4.0 - 7.4.33 , 8.0.0 - 8.0.30 , 8.1.0 - 8.1.28 , 8.2.0 - 8.2.18 , 8.3.0 - 8.3.6 http://vnexpress.net/tin-tuc/phap-luat/15-canh-sat-bi-bat-giu-tai-my-duc-duoc-tha-tu-do-3571959.html
Fatal error: Uncaught Error: Call to undefined function curl_init() in /in/tvj8Z:4
Stack trace:
#0 {main}
thrown in /in/tvj8Z on line 4
Process exited with code 255 . preferences:dark mode live preview
192.57 ms | 404 KiB | 171 Q