Skip to content

Instantly share code, notes, and snippets.

@tmcw
Created September 5, 2012 18:39
Show Gist options
  • Save tmcw/3642285 to your computer and use it in GitHub Desktop.
Save tmcw/3642285 to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html>
<head>
<script src='http://api.tiles.mapbox.com/mapbox.js/v0.6.5/mapbox.js'></script>
<link href='http://api.tiles.mapbox.com/mapbox.js/v0.6.5/mapbox.css' rel='stylesheet' />
<style>
body { margin:0; padding:0; }
#map { position:absolute; top:0; bottom:0; width:100%; }
</style>
</head>
<body>
<div id='map'></div>
<script>
(function() {
var makimap = mapbox.map('map', mapbox.layer().id('saman.map-kg3gj8s6', function(l) {
var t = l.tilejson();
t.attribution = 'POI data from <a href="http://downloads.cloudmade.com/americas/northern_america/united_states/district_of_columbia#downloads_breadcrumbs">cloudmade</a> via OpenStreetMap <a href="http://creativecommons.org/licenses/by-sa/2.0">CC BY-SA 2.0</a>';
l.tilejson(t);
console.log(t);
makimap.ui.refresh();
makimap.ui.attribution.add();
makimap.centerzoom({ lat: 38.91710, lon: -77.03024 }, 17).setZoomRange(3, 17);
}));
})();
</script>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment