Skip to content

Instantly share code, notes, and snippets.

@samanpwbb samanpwbb/map.html
Created Jan 7, 2016

Embed
What would you like to do?
<html>
<head>
<link rel="stylesheet" type="text/css" href="http://cdn.leafletjs.com/leaflet/v0.7.7/leaflet.css">
<script src='http://cdn.leafletjs.com/leaflet/v0.7.7/leaflet.js'></script>
<style>
body { margin:0; padding:0; }
#map { position:absolute; top:0; bottom:0; width:100%; }
</style>
</head>
<body>
<div id='map'></div>
<script>
var imagery = L.tileLayer('http://api3.weather.com/v2/TileServer/tile/radarConus?ts=1452120300&xyz={x}:{y}:{z}&apiKey=3d498bd0777076fb2aa967aa67114c7e'
);
var ground = L.tileLayer("https://api.tiles.mapbox.com/v4/{id}/{z}/{x}/{y}.png?access_token={accessToken}", {
maxZoom: 18,
id: 'weather.c90mkbha',
accessToken: 'pk.eyJ1Ijoid2VhdGhlciIsImEiOiJjaWk2bzk1eG8wMXJhdHdrZjJjMmJxNzJjIn0.kYeed_5RIEgpXcqodNVR4w'
});
var labels = L.tileLayer("https://api.tiles.mapbox.com/v4/{id}/{z}/{x}/{y}.png?access_token={accessToken}", {
maxZoom: 18,
id: 'weather.64j667v4',
accessToken: 'pk.eyJ1Ijoid2VhdGhlciIsImEiOiJjaWk2bzk1eG8wMXJhdHdrZjJjMmJxNzJjIn0.kYeed_5RIEgpXcqodNVR4w'
});
var map = L.map('map', {
center: [37.7833, -122.4167],
zoom: 8,
layers: [ground, imagery, labels]
});
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.