annotate client/digitallibrary/dlImage.jsp @ 61:bacf7d60f185

Forgot to enter changes in CHANGES file. (ROC)
author robcast
date Wed, 28 Aug 2002 21:03:30 +0200
parents 58d23f512c80
children b877e54b0794
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
33
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
1 <%
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
2 // checking if the height and width of this client is already known
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
3 if ((request.getParameter("dw") == null) || (request.getParameter("dh") == null)) {
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
4 %>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
5
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
6 <html>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
7 <head>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
8 <script language="Javascript">
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
9
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
10 function redirect() {
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
11
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
12 if (navigator.appName.toLowerCase() == "netscape") { // mozilla-browsers (netscape 4.xx, netscape 6.xx, etc.)
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
13 client = "&dw=" + (innerWidth-30) + "&dh=" + (innerHeight-30);
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
14 } else { // ie
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
15 client = "&dw=" + (document.body.clientWidth-30) + "&dh=" + (document.body.clientHeight-30);
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
16 }
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
17
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
18 location.replace("dlImage.jsp?<%= request.getQueryString() %>" + client);
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
19 }
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
20
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
21 </script>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
22 </head>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
23 <body bgcolor="#666666" onload="redirect()">
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
24 </body>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
25 </html>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
26
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
27 <%
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
28 } else {
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
29
60
58d23f512c80 New DigilibServlet.jar with new version (with DigilibRequest object).
robcast
parents: 50
diff changeset
30 digilib.servlet.DigilibRequest dlRequest = new digilib.servlet.DigilibRequest();
33
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
31 // default values for parameters
60
58d23f512c80 New DigilibServlet.jar with new version (with DigilibRequest object).
robcast
parents: 50
diff changeset
32 dlRequest.setFn("/"); // url of the page/document
58d23f512c80 New DigilibServlet.jar with new version (with DigilibRequest object).
robcast
parents: 50
diff changeset
33 dlRequest.setPn(1); // page number
58d23f512c80 New DigilibServlet.jar with new version (with DigilibRequest object).
robcast
parents: 50
diff changeset
34 dlRequest.setWs(1); // scale factor
58d23f512c80 New DigilibServlet.jar with new version (with DigilibRequest object).
robcast
parents: 50
diff changeset
35 dlRequest.setMo(""); // special options like 'fit' for gifs
58d23f512c80 New DigilibServlet.jar with new version (with DigilibRequest object).
robcast
parents: 50
diff changeset
36 dlRequest.setMk("0/0"); // marks
58d23f512c80 New DigilibServlet.jar with new version (with DigilibRequest object).
robcast
parents: 50
diff changeset
37 dlRequest.setWx(0); // left edge of image (float from 0 to 1)
58d23f512c80 New DigilibServlet.jar with new version (with DigilibRequest object).
robcast
parents: 50
diff changeset
38 dlRequest.setWy(0); // top edge in image (float from 0 to 1)
58d23f512c80 New DigilibServlet.jar with new version (with DigilibRequest object).
robcast
parents: 50
diff changeset
39 dlRequest.setWw(1); // width of image (float from 0 to 1)
58d23f512c80 New DigilibServlet.jar with new version (with DigilibRequest object).
robcast
parents: 50
diff changeset
40 dlRequest.setWh(1); // height of image (float from 0 to 1)
33
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
41 // overrriding default parameters with provided parameters from query-string
60
58d23f512c80 New DigilibServlet.jar with new version (with DigilibRequest object).
robcast
parents: 50
diff changeset
42 dlRequest.setWithRequest(request);
33
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
43
50
866e798e2bef 13.8.2002 - [different files] : roc
robcast
parents: 41
diff changeset
44 //String imageLocation = "http://" + request.getServerName() + "/docuserver/digitallibrary/servlet/Scaler/" + fn + "?pn=" + pn + "&ws=" + ws + "&mo=" + mo + "&wx=" + wx + "&wy=" + wy + "&ww=" + ww + "&wh=" + wh + "&dw=" + dw + "&dh=" + dh;
866e798e2bef 13.8.2002 - [different files] : roc
robcast
parents: 41
diff changeset
45
60
58d23f512c80 New DigilibServlet.jar with new version (with DigilibRequest object).
robcast
parents: 50
diff changeset
46 String baseUrl = dlRequest.getBaseURL();
50
866e798e2bef 13.8.2002 - [different files] : roc
robcast
parents: 41
diff changeset
47
60
58d23f512c80 New DigilibServlet.jar with new version (with DigilibRequest object).
robcast
parents: 50
diff changeset
48 String imageLocation = dlRequest.getBaseURL() + "/servlet/Scaler/?" + dlRequest.getAsString();
33
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
49 %>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
50
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
51 <html>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
52 <head>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
53 <script language="JavaScript">
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
54
60
58d23f512c80 New DigilibServlet.jar with new version (with DigilibRequest object).
robcast
parents: 50
diff changeset
55 var baseUrl = "<%= dlRequest.getBaseURL() %>";
50
866e798e2bef 13.8.2002 - [different files] : roc
robcast
parents: 41
diff changeset
56
33
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
57 // browser version test to include the corresponding navigation-file
41
44f653ae5df5 opera support done, bugfixes
luginbue
parents: 33
diff changeset
58 if (navigator.userAgent.toLowerCase().indexOf("opera") > -1) {
44f653ae5df5 opera support done, bugfixes
luginbue
parents: 33
diff changeset
59 document.write('<script src="navigation_o6.js"><\/script>');
44f653ae5df5 opera support done, bugfixes
luginbue
parents: 33
diff changeset
60 } else if (navigator.userAgent.toLowerCase().indexOf("msie") > -1) {
44f653ae5df5 opera support done, bugfixes
luginbue
parents: 33
diff changeset
61 document.write('<script src="navigation_ie.js"><\/script>');
44f653ae5df5 opera support done, bugfixes
luginbue
parents: 33
diff changeset
62 } else if (navigator.userAgent.toLowerCase().indexOf("mozilla\/4") > -1) {
33
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
63 document.write('<script src="navigation_n4.js"><\/script>');
41
44f653ae5df5 opera support done, bugfixes
luginbue
parents: 33
diff changeset
64 } else if (navigator.userAgent.toLowerCase().indexOf("mozilla\/5") > -1) {
33
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
65 document.write('<script src="navigation_n6.js"><\/script>');
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
66 } else {
41
44f653ae5df5 opera support done, bugfixes
luginbue
parents: 33
diff changeset
67 alert('Your browser is not directly supported by this client right now.\n\nLoading now the optimised version for Netscape 6, that sticks the most to the w3c specifications.');
33
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
68 document.write('<script src="navigation_n6.js"><\/script>');
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
69 }
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
70
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
71 // add module to show the total number of pages (not browser dependant!)
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
72 document.write('<script src="modules\/pagesTotal.js"><\/script>');
50
866e798e2bef 13.8.2002 - [different files] : roc
robcast
parents: 41
diff changeset
73 // document.write('<script src="modules\/pdfMaker.js"><\/script>');
33
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
74
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
75 </script>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
76 </head>
60
58d23f512c80 New DigilibServlet.jar with new version (with DigilibRequest object).
robcast
parents: 50
diff changeset
77 <body bgcolor="#666666" onload='init_pagesTotal("<%= dlRequest.getFn() %>", "<%= dlRequest.getPn() %>", "<%= dlRequest.getWs() %>", "<%= dlRequest.getMo() %>", "<%= dlRequest.getMk() %>", "<%= dlRequest.getWx() %>", "<%= dlRequest.getWy() %>", "<%= dlRequest.getWw() %>", "<%= dlRequest.getWh() %>", "<%= dlRequest.getPt() %>")'>
33
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
78
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
79 <div id="lay1" style="position: absolute; left: 10px; top: 10px; visibility: visible"><img name="pic" src="<%= imageLocation %>" border="0"></div>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
80
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
81 <div id="dot0" style="position: absolute; left: -20; top: 100; visibility: hidden"><img src="mark1.gif" border="0"></div>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
82 <div id="dot1" style="position: absolute; left: -20; top: 100; visibility: hidden"><img src="mark2.gif" border="0"></div>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
83 <div id="dot2" style="position: absolute; left: -20; top: 100; visibility: hidden"><img src="mark3.gif" border="0"></div>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
84 <div id="dot3" style="position: absolute; left: -20; top: 100; visibility: hidden"><img src="mark4.gif" border="0"></div>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
85 <div id="dot4" style="position: absolute; left: -20; top: 100; visibility: hidden"><img src="mark5.gif" border="0"></div>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
86 <div id="dot5" style="position: absolute; left: -20; top: 100; visibility: hidden"><img src="mark6.gif" border="0"></div>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
87 <div id="dot6" style="position: absolute; left: -20; top: 100; visibility: hidden"><img src="mark7.gif" border="0"></div>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
88 <div id="dot7" style="position: absolute; left: -20; top: 100; visibility: hidden"><img src="mark8.gif" border="0"></div>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
89 <div id="eck1" style="position: absolute; left: -20; top: 100; visibility: hidden"><img src="olinks.gif" border="0"></div>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
90 <div id="eck2" style="position: absolute; left: -20; top: 100; visibility: hidden"><img src="orechts.gif" border="0"></div>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
91 <div id="eck3" style="position: absolute; left: -20; top: 100; visibility: hidden"><img src="ulinks.gif" border="0"></div>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
92 <div id="eck4" style="position: absolute; left: -20; top: 100; visibility: hidden"><img src="urechts.gif" border="0"></div>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
93 </body>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
94 </html>
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
95 <%
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
96 }
054ebc851059 first update of new client-version
luginbue
parents:
diff changeset
97 %>