Skip to content

Instantly share code, notes, and snippets.

@ryanjhodge
Last active November 27, 2015 20:26
Show Gist options
  • Save ryanjhodge/2c497c27cc10c9500cf1 to your computer and use it in GitHub Desktop.
Save ryanjhodge/2c497c27cc10c9500cf1 to your computer and use it in GitHub Desktop.
NPMap.js Lewis and Clark National Historic Site Vegetation Inventory Map (Mapbox)
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=no">
<title>NPMap.js Lewis and Clark National Historic Site Vegetation Inventory Map</title>
<style>
body {
margin: 0;
padding: 0;
}
#map {
bottom: 0;
position: absolute;
top: 0;
width: 100%;
}
</style>
</head>
<body>
<div id="map"></div>
<script>
var NPMap = {
div: 'map',
fullscreenControl: true,
infoboxControl: true,
zoomdisplayControl: true,
hashControl: true,
zoom: 11,
center: {
"lat": 46.2031,
"lng": -123.9615
},
overlays: [{
id: 'ryanjhodge.4c6f39a2',
type: 'mapbox',
popup: false,
tooltip: '<b>Division:</b> {{division_name}}<br/><b>Alliance:</b> {{alliance_common_name}}<br/><b>Vegetation Unit:</b> {{mapunit_name}}'
}]
};
(function() {
var s = document.createElement('script');
s.src = 'http://www.nps.gov/lib/npmap.js/3.0.7/npmap-bootstrap.min.js';
document.body.appendChild(s);
})();
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment