Template:Fragoria Map
From FragoriaWiki
(Difference between revisions)
												
			
		| Line 43: | Line 43: | ||
			position: new google.maps.LatLng(-89.62,66.4),  | 			position: new google.maps.LatLng(-89.62,66.4),  | ||
			map: map,  | 			map: map,  | ||
| + | draggable:true,  | ||
			title:"Fragotown"  | 			title:"Fragotown"  | ||
		});  | 		});  | ||
| - | google.maps.event.  | + | google.maps.event.addListener(myMarker, 'dragend', function(evt){  | 
| - | + |     document.getElementById('current').innerHTML = '<p>Marker dropped: Current Lat: ' + evt.latLng.lat().toFixed(3) + ' Current Lng: ' + evt.latLng.lng().toFixed(3) + '</p>';  | |
| + | });  | ||
| + | |||
| + | google.maps.event.addListener(myMarker, 'dragstart', function(evt){  | ||
| + |     document.getElementById('current').innerHTML = '<p>Currently dragging marker...</p>';  | ||
});  | });  | ||
| Line 83: | Line 88: | ||
<body onload="initialize()">     | <body onload="initialize()">     | ||
<center>  | <center>  | ||
| + | <div id="current">Coordinates</div>  | ||
	<div style="box-shadow: 2px 2px 5px #999999;border: 1px solid black;width: 97%; height: 585px;background-image:url('/wiki/images/1/1f/Background.jpg');" id="map_canvas">  | 	<div style="box-shadow: 2px 2px 5px #999999;border: 1px solid black;width: 97%; height: 585px;background-image:url('/wiki/images/1/1f/Background.jpg');" id="map_canvas">  | ||
	</div>  | 	</div>  | ||
Revision as of 03:44, 5 April 2015
Coordinates
	
				
				
				
				
				
	
			