can’t seem to get this parser to work for google maps, I think its because there is no xml extension? It works on a xml file that I make, but when I use google xml it doesn’t seem to want to grab it.
<?php
$address = 'edgemont dr wyoming, MI';
$address = rawurlencode ($address);
$url = 'http://maps.google.com/maps/api/geocode/xml?address=' . $address . '&sensor=false';
$link = '<a href="' . $url . '">' . $url . '</a>';
echo $link;
$xml = simplexml_load_file($url);
// get Latitude from XML
$lat=$xml->GeocodeResponse->result->geometry->location->lat;
echo $lat;
?>
You could change this:
to this