lat,lng D: destination address •In general browser, it will open the Google Maps site and compute directions directly •In iPhone/Android, the URL will open the Google Maps app on the phone and show the directions.
data on your website through the JavaScript/Flex/Static API. •What you can do: ◦ Show data on a map ◦ Get directions/address lookup via GeoCoder service ◦ Show a streeview ◦ Use map as a geo input interface ◦ ...
YOUR_API_KEY"></script> <script type="text/javascript"> // load google maps library (v2) google.load('maps', 2); google.setOnLoadCallback(function(){ // create a Map2 instance, and draw it on #map_canvas var canvas = document.getElementById('map_canvas'); var map = new google.maps.Map2(canvas, { size: new google.maps.Size(400, 300) }); // set the center of the map map.setCenter(new google.maps.LatLng(25.030978,121.560287), 15); }); </script>
google maps library (v2) google.load('maps', 2); google.setOnLoadCallback(function(){ .... // create a marker var marker = new google.maps.Marker( new google.maps.LatLng(LATITUDE, LONGITUDE), {draggable: true}); // add the marker onto the map map.addOverlay(marker); }); </script>
google maps library (v2) google.load('maps', 2); google.setOnLoadCallback(function(){ .... // create a marker var marker = new google.maps.Marker(...); // listen the ``dragend'' event of the marker google.maps.Event.addListener(marker, 'dragend', function(latlng) { // call on the dragend event is triggered } ); // add the marker onto the map map.addOverlay(marker); }); </script> Google Maps API Ref.
a web service that generates a map image ◦Use <img src="http://....." alt=""> to use this API ◦One client can only access 1000 times/day •Lack of map controls but easy to use