Is there any way to get html source code of external url using cUrl or rest api. As in php we can get by using following code.
$ch = curl_init("http://www.example-webpage.com/file.html");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_BINARYTRANSFER, true);
$content = curl_exec($ch);
curl_close($ch);
Can we achieve something like this in Apex ?
Any help will be appreciated.