forked from resultstrackmap/geo_map
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy patht6.html
65 lines (53 loc) · 1.93 KB
/
t6.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8 />
<title>India map </title>
<meta name='viewport' content='initial-scale=1,maximum-scale=1,user-scalable=no' />
<script src='https://api.tiles.mapbox.com/mapbox.js/v2.3.0/mapbox.js'></script>
<link href='https://api.tiles.mapbox.com/mapbox.js/v2.3.0/mapbox.css' rel='stylesheet' />
<script src='https://api.tiles.mapbox.com/mapbox.js/plugins/leaflet-hash/v0.2.1/leaflet-hash.js'></script>
<style>
body { margin:0; padding:0; }
#map { position:absolute; top:0; bottom:0; width:100%; }
</style>
</head>
<body>
<section class="map-container {{page.map}}">
<div id='map'></div>
</span>
</section>
<script>
var southWest = L.latLng(7.319, 61.523),
northEast = L.latLng(36.774, 100.635),
bounds = L.latLngBounds(southWest, northEast);
L.mapbox.accessToken = 'pk.eyJ1Ijoib3BlbnN0cmVldG1hcCIsImEiOiJhNVlHd29ZIn0.ti6wATGDWOmCnCYen-Ip7Q';
var indiaMap = L.mapbox.tileLayer('openstreetmap.1b68f018'),
bhuvanSatellite = L.tileLayer('http://tile1.nrsc.gov.in/tilecache/tilecache.py/1.0.0/bhuvan_imagery2/{z}/{x}/{y}.jepg', {
attribution: 'NRSC/ISRO'
}),
postalMap = L.mapbox.tileLayer('planemad.9acc2036'),
highwaysMap = L.mapbox.tileLayer('planemad.66359ac0'),
connectivityGraph = L.mapbox.tileLayer('planemad.5504651b'),
railwayMap = L.mapbox.tileLayer('planemad.e5dd1290');
var baseLayers = {
"Railway Map": railwayMap,
"Bhuvan Satellite": bhuvanSatellite,
"OpenStreetMap India": indiaMap
};
var map = L.map('map', {
layers: indiaMap
}, {
maxBounds: bounds,
})
.addControl(L.mapbox.geocoderControl('mapbox.places', {
autocomplete: true
}))
.setView([22.14980, 79.08060], 4);
L.hash(map);
L.control.layers(baseLayers, overlayMaps, {
position: 'topleft',
}).addTo(map);
</script>
</body>
</html>