Skip to content

Instantly share code, notes, and snippets.

@MappingKat
Last active September 28, 2015 22:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save MappingKat/efc18d8b5193c8561b92 to your computer and use it in GitHub Desktop.
Save MappingKat/efc18d8b5193c8561b92 to your computer and use it in GitHub Desktop.
Basic Leaflet map
<!DOCTYPE html>
<html>
<head>
<title>Simple Leaflet Map</title>
<meta charset="utf-8" />
<link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet-0.7/leaflet.css" />
</head>
<body>
<div id="map" style="width: 1100px; height: 800px"></div>
<script src="http://cdn.leafletjs.com/leaflet-0.7/leaflet.js"></script>
<script>
var map = L.map('map').setView([39.739, -104.9903], 15);
L.tileLayer(
'http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
attribution: '&copy; <a href="http://openstreetmap.org">OpenStreetMap</a> Contributors',
maxZoom: 18,
}).addTo(map);
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment