Cod: Selectaţi tot
<?php
$map_info = array();
$map_info['center'] = 'calle+bruc,LLeida,Spain';
$map_info['zoom'] = '15';
$map_info['size'] = '640x500';
$map_info['maptype'] = 'roadmap';
$map_info['markers'] = 'size:mid%7Ccolor:red%7C'.$map_info['center'];
$map_info['sensor'] = 'false';
$map_info['patch'] = '';
?>
<img src="<?php echo 'http://maps.googleapis.com/maps/api/staticmap?';
foreach($map_info as $key => $value)
echo '&'.$key.'='.$value;
?>" />
// rezultat url: http://maps.googleapis.com/maps/api/staticmap?¢er=calle+bruc,LLeida,Spain&zoom=15&size=640x500&maptype=roadmap&markers=size:mid%7Ccolor:red%7Ccalle+bruc,LLeida,Spain&sensor=false&patch=
// documentatie: http://code.google.com/apis/maps/documentation/staticmaps/#Addresses
Va salut!
Am pus mai sus codul pe care l-am creat dupa documentatia Google.
In codul de mai sus, pozitionez harta in functie de adresa si orasul utilizatorului prin $map_info['center'] = 'calle+bruc,LLeida,Spain';
Intrebarea mea este: se poate pozitiona dupa codul postal?
Multumesc!