I'm just getting into using gmapEZ but I've been using the gmap API
for awhile.
You can geocode the address to get the lat/long.
To help you get going, the following code (which I found on the Google
Maps site) will allow you to get the lat/long from a given address.
You still need to add or modify the rest of the code for this to work
with gmapEZ.
I hope this helps point you in the right direction.
// Initialize delay in geocode speed
$delay = 0;
define("KEY", "Use-Your-Code-Here");
$base_url = "
http://maps.google.com/maps/geo?output=csv&key=" . KEY;
$geocode_pending = true;
while ($geocode_pending) {
// $address=$city.', '.$state.', '.$zip.', '.$country;
$address=$city.', '.$state.', '.$country;
$request_url = $base_url . "&q=" . urlencode($address);
$csv = file_get_contents($request_url) or die("url not loading");
$csvSplit = split(",", $csv);
$geocode_status = $csvSplit[0];
$lat = $csvSplit[2];
$lng = $csvSplit[3];
if (strcmp($geocode_status, "200") == 0) {
// successful geocode
$geocode_pending = false;
$lat = mysql_real_escape_string($lat);
$lng = mysql_real_escape_string($lng);
}
else if (strcmp($geocode_status, "620") == 0) {
// sent geocodes too fast
$delay += 100000;
}
else {
// failure to geocode
$geocode_pending = false;
$lat = 0;
$lng = 0;
}
usleep($delay);
}