forked from tokee/juxta
-
Notifications
You must be signed in to change notification settings - Fork 0
/
demo_kb.template.html
62 lines (55 loc) · 2.33 KB
/
demo_kb.template.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
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.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" />
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Images from kb.dk - ${COLLECTION}</title>
<link rel="stylesheet" type="text/css" href="resources/juxta.css" />
<script src="resources/openseadragon.min.js"></script>
<script type="text/javascript" src="resources/overlays_preload.js"></script>
<script type="text/javascript" src="resources/overlays.js"></script>
<!-- Contact person: [email protected] -->
</head>
<body>
<h1>${TOTAL_IMAGES} images from kb.dk (${MEGAPIXELS} MPixels) - ${COLLECTION}</h1>
<p>Juxta-demo of publicly available images from <a href="http://www.kb.dk/images/billed/2010/okt/billeder/subject2109/da/">kb.dk</a>. Please see the kb.dk-pages for license information.</p>
<div id="zoom-display" class="openseadragon"><div id="header"></div><div id="infobox"></div><div id="footer"></div></div>
<script type="text/javascript">
var myDragon = OpenSeadragon({
id: "zoom-display",
maxZoomPixelRatio: ${MAX_ZOOM_PIXEL_RATIO},
zoomPerScroll: 2.0,
showNavigator: false,
wrapHorizontal: false,
prefixUrl: "resources/images/",
${TILE_SOURCES}
});
${SETUP_OVERLAY}
</script>
<script type="text/javascript">
overlays.createHeader = function(x, y, image, meta) {
imageId = image.substring(image.lastIndexOf('/')+1).replace(/\.[^/.]+$/, "");
imageLink = meta.split("§")[0];
linkText = meta.split("§")[1];
return '<a href="' + imageLink + '">' + linkText + '</a>';
}
overlays.createFooter = function(x, y, image, meta) {
var copyright = meta.split("§")[3];
if ( copyright == '') {
copyright = "Unknown";
}
var description = meta.split("§")[2];
if (description != '') {
description += '<br/>';
}
return description + '<span class="copyright"><span class="copyrightlabel">Copyright:</span> <span class="copyrighttext">' + copyright + '</span></span>';
}
</script>
<p>Generated `date +"%Y-%m-%d %H:%M"`</p>
<!-- Must be below the creation of myDragon -->
<script type="text/javascript" src="resources/overlays.js"></script>
<script type="text/javascript">
</script>
</body>
</html>