Created
November 5, 2016 13:24
-
-
Save theredstapler/befd06a7a5cfde9119a591ddac10a915 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
<html> | |
<head> | |
<script src="jquery-2.1.4.js"></script> | |
<link rel="stylesheet" type="text/css" href="styles.css"> | |
<style> | |
#map { | |
height: 500px; | |
} | |
</style> | |
</head> | |
<body> | |
<div id="navbar"><span>Google Maps - Javascript API</span></div> | |
<div id="wrapper"> | |
<div id="map"></div> | |
<script> | |
var map; | |
function initMap() { | |
map = new google.maps.Map(document.getElementById('map'), { | |
center: {lat: -34.397, lng: 150.644}, | |
zoom: 9 | |
}); | |
var marker = new google.maps.Marker({ | |
position: {lat: -34.397, lng: 150.644}, | |
map: map, | |
title: 'Hello World!', | |
icon: 'pin.png', | |
animation: google.maps.Animation.BOUNCE, | |
draggable: true | |
}); | |
} | |
</script> | |
<script src="https://maps.googleapis.com/maps/api/js?key=API_KEY&callback=initMap" | |
async defer></script> | |
</div> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
good