Created
April 8, 2017 03:11
-
-
Save evilnapsis/3321c4bf7c87da3db095d4b2622dde3c to your computer and use it in GitHub Desktop.
Ejemplo de Mapa usando Google Maps API v3, Agregar Marcadores
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<!-- Powered by Evilnapsis 2017 --> | |
<html> | |
<head> | |
<title>Google Maps API v3: Agregar Marcadores Simples</title> | |
</head> | |
<body> | |
<h1>Google Maps API v3: Agregar Marcadores Simples</h1> | |
<div id="map" style="width:100%;height:600px;"></div> | |
<script type="text/javascript"> | |
var map; | |
var centerll = {lat: 23.63, lng: -102.55}; | |
function initMap() { | |
map = new google.maps.Map(document.getElementById('map'), { | |
center: centerll, | |
zoom: 6 | |
}); | |
var marker1 = new google.maps.Marker({ | |
position: centerll, | |
map:map | |
}); | |
var marker2 = new google.maps.Marker({ | |
position: {lat: 23.93, lng: -102.85}, | |
map:map | |
}); | |
} | |
</script> | |
<script async defer | |
src="https://maps.googleapis.com/maps/api/js?key=AIzaSyDuBEidKGDuQo7Bzf1uRg47MPaRRlEesw0&callback=initMap"> | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thanks a lot.