0

I trying to "get" a URL of www.gsmarena.com for scraping. The underlying HTTP GET request is working alright with PHP CURL code:

$curl = curl_init();
curl_setopt ($curl, CURLOPT_URL, "http://www.gsmarena.com/lg_nexus_5-5705.php");
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);

$result = curl_exec ($curl);
curl_close ($curl);

But I don't want to use PHP CURL. I want to do the same thing using JQUERY AJAX following codepen I created:

http://codepen.io/amigoo/pen/qZGmqq?editors=1111

But I am getting this error: enter image description here

Faisal Ashfaq
  • 2,545
  • 4
  • 28
  • 41

0 Answers0