-
Notifications
You must be signed in to change notification settings - Fork 22
/
mapremote.html
36 lines (34 loc) · 1.66 KB
/
mapremote.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
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html id='docHTML'>
<head>
<title>Tabulator: Async Javascript And Semantic Web</title>
<link rel="stylesheet" href="chrome://tabulator/content/tabbedtab.css" type="text/css" />
<link rel="stylesheet" href="chrome://tabulator/content/mapView.css" type="text/css" />
<script src="js/views/mapView-ext.js" type="text/javascript"></script>
<script src="js/rdf/util.js" type="text/javascript"></script>
<script src="js/tab/util-nonlib.js" type="text/javascript"></script>
<!-- Script for Google Maps API - WARNING: Only works for dig.csail.mit.edu-originating requests -->
<script src="http://maps.google.com/maps?file=api&v=2&key=ABQIAAAAc5soiwASdnA8N5abQqG3pBTJK_aDg4EoIC66fat1oOogJpoOYxRCy9Ektk6AIGW_c_nGt8wZICp5zA" type="text/javascript">
</script>
</head>
<body>
<div class="viewArea" id="viewArea" style="width:100%;height:100%;">
</div>
</body>
<script type="text/javascript">
var myMapView = new mapView(document.getElementById('viewArea'));
myMapView.onActive();
function addMarker(e) {
var info = e.originalTarget;
document.documentElement.removeChild(info);
var markerData = eval(info.getAttribute('mapViewData'));
var marker = new GMarker(new GLatLng(parseFloat(markerData.lat),parseFloat(markerData.lng)));
GEvent.addListener(marker, "click", function() {
marker.openInfoWindow(info);
});
myMapView.map.addOverlay(marker);
}
document.addEventListener("TabulatorMapEvent",addMarker,false);
</script>
</html>