36 lines
1.3 KiB
HTML
36 lines
1.3 KiB
HTML
<html>
|
|
<!--
|
|
vim: sts=4 sw=4 et
|
|
-->
|
|
<head>
|
|
<title>Leaflet</title>
|
|
<link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet-0.7/leaflet.css" />
|
|
<link rel="stylesheet" href="../css/distance.css" />
|
|
<link rel="stylesheet" href="http://leaflet.github.io/Leaflet.draw/leaflet.draw.css" />
|
|
<script src="http://cdn.leafletjs.com/leaflet-0.7/leaflet.js"></script>
|
|
<script src="http://leaflet.github.io/Leaflet.draw/leaflet.draw.js"></script>
|
|
<script src="../layer/vector/GPX.js"></script>
|
|
<script src="../control/Scale.js"></script>
|
|
<script src="../control/Permalink.js"></script>
|
|
<script src="../control/Permalink.Line.js"></script>
|
|
<script src="../control/Distance.js"></script>
|
|
</head>
|
|
</head>
|
|
<body>
|
|
<!-- define a DIV into which the map will appear. Make it take up the whole window -->
|
|
<div style="width:100%; height:100%" id="map"></div>
|
|
<script type='text/javascript'>
|
|
</script>
|
|
<script type="text/javascript">
|
|
|
|
var map = new L.Map('map', {center: new L.LatLng(58.4, 43.0), zoom: 11});
|
|
var osm = new L.TileLayer('http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png');
|
|
|
|
map.addLayer(osm);
|
|
var d = new L.Control.Distance(); map.addControl(d);
|
|
map.addControl(new L.Control.Scale());
|
|
map.addControl(new L.Control.Permalink({line: d.getLine(), useLocation: true}));
|
|
|
|
</script>
|
|
</body>
|
|
</html>
|