I'm trying to get some data from a website using PHP Curl as follows:-
$url_1 = "website.com"
$url_2 = "http://www.website.com"
$url_3 = "http://www." . $url_1;
$ch = curl_init($url_1); // failure
$ch = curl_init($url_2); // success
$ch = curl_init($url_3); // failure
I have a huge list of URLS in the format of $url_1 please will you let me know how I can add the http:// prefix to the url so it can be accepted by curl_init()
Thanks