PHP Simple HTML Dom not parsing certain links PHP Simple HTML Dom not parsing certain links curl curl

PHP Simple HTML Dom not parsing certain links


It seems to work when you add/spoof it with a browser agent:

$base = 'http://www.flipkart.com/samsung-galaxy-s6/p/itme5z4aypvtrxmy';$curl = curl_init($base);curl_setopt($curl, CURLOPT_FOLLOWLOCATION, true);curl_setopt($curl,CURLOPT_USERAGENT,'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.13) Gecko/20080311 Firefox/2.0.0.13');curl_setopt($curl, CURLOPT_RETURNTRANSFER, TRUE);$str = curl_exec($curl);curl_close($curl);echo $str;