-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmap.html
75 lines (65 loc) · 1.86 KB
/
map.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
66
67
68
69
70
71
72
73
74
75
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title>Карта</title>
<script charset="utf-8" type="text/javascript" src="http://api-maps.yandex.ru/1.0/?key=ALA-HEkBAAAAWA7dRQMA1tU9drgY14m-mw5ZOdnrjLKyLIwAAAAAAAAAAACEbj_BEO_HXptK6butt69Bqhhowg=="></script>
<style>
html {height:100%;width:100%}
body {height:100%;width:100%;margin:0;padding:0}
#YMapsID {height:100%;width:100%}
.YMaps-b-balloon-content ul {
padding:0 0 5px 15px;
}
.YMaps-b-balloon-content p img, .YMaps-b-balloon-content p img {
float:left;
padding:0 5px 5px 0;
}
.YMaps-b-balloon-content p {
padding:5px 0;
}
.clear {
clear:both;
}
</style>
<script type="text/javascript"><!--
var map;
var places = new Array();
function initMap() {
map = new YMaps.Map(document.getElementById("YMapsID"));
map.addControl(new YMaps.TypeControl());
map.addControl(new YMaps.ToolBar());
map.addControl(new YMaps.Zoom());
map.addControl(new YMaps.ScaleLine());
}
function init(long, lat) {
map.setCenter(new YMaps.GeoPoint(long, lat), 16);
map.setZoom(12);
};
function clearPlaces() {
while (places.length > 0) {
var placemark = places.pop();
map.removeOverlay(placemark);
}
}
function addPlace(long, lat, text) {
var point = new YMaps.GeoPoint(long, lat);
var placemark = new YMaps.Placemark(point);
placemark.description = text;
map.addOverlay(placemark);
places.push(placemark);
}
window.onload = function onLoad() {
initMap();
init('37.609281', '55.753635');
// addPlace('37.678514', '55.758255', ':-)');
// clearPlaces();
// init('37.678514', '55.758255');
}
//--></script>
</head>
<body>
<div id="YMapsID"></div>
</body>
</html>