I am trying to scrap data off google finance using php..I am trying to extract the usd to zar conversion rate from google finance site...There seems to be some sort of error in the regular expression i am using...could someone please suggest me the correct method...Below is my code...
<?php
$page = file_get_contents('https://www.google.com/finance?q=USDZAR');
echo $page;
preg_match("/<span class=\"bld\".*span>/", $page, $conversion_rate);
print_r($conversion_rate);
?>
I am getting am empty array