35 lines
1.1 KiB
HTML
35 lines
1.1 KiB
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<title>Leaflet debug page</title>
|
|
|
|
<link rel="stylesheet" href="../../dist/leaflet.css" />
|
|
<!--[if lte IE 8]><link rel="stylesheet" href="../../dist/leaflet.ie.css" /><![endif]-->
|
|
|
|
<link rel="stylesheet" href="../css/screen.css" />
|
|
|
|
<script src="../include.js"></script>
|
|
</head>
|
|
<body>
|
|
<div id="map" style="width: 800px; height: 600px; border: 1px solid #ccc"></div>
|
|
|
|
<script src="route.js"></script>
|
|
<script>
|
|
var cloudmadeUrl = 'http://{s}.tile.cloudmade.com/BC9A493B41014CAABB98F0471D759707/997/256/{z}/{x}/{y}.png',
|
|
cloudmade = new L.TileLayer(cloudmadeUrl, {maxZoom: 18});
|
|
|
|
var map = new L.Map('map');
|
|
|
|
var london = new L.LatLng(51.505, -0.09); // geographical point (longitude and latitude)
|
|
map.setView(london, 13).addLayer(cloudmade);
|
|
|
|
var p1 = new L.LatLng(51.509, -0.08),
|
|
p2 = new L.LatLng(51.503, -0.06),
|
|
p3 = new L.LatLng(51.51, -0.047),
|
|
polygonPoints = [p1, p2, p3];
|
|
|
|
var polygon = new L.Polygon(polygonPoints);
|
|
map.addLayer(polygon);
|
|
</script>
|
|
</body>
|
|
</html> |