1 |
4235
|
leinfelder
|
<%@ page language="java" %>
|
2 |
|
|
<%
|
3 |
|
|
/**
|
4 |
|
|
*
|
5 |
|
|
* '$RCSfile$'
|
6 |
|
|
* Copyright: 2008 Regents of the University of California and the
|
7 |
|
|
* National Center for Ecological Analysis and Synthesis
|
8 |
|
|
* '$Author$'
|
9 |
|
|
* '$Date$'
|
10 |
|
|
* '$Revision$'
|
11 |
|
|
*
|
12 |
|
|
* This program is free software; you can redistribute it and/or modify
|
13 |
|
|
* it under the terms of the GNU General Public License as published by
|
14 |
|
|
* the Free Software Foundation; either version 2 of the License, or
|
15 |
|
|
* (at your option) any later version.
|
16 |
|
|
*
|
17 |
|
|
* This program is distributed in the hope that it will be useful,
|
18 |
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
19 |
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
20 |
|
|
* GNU General Public License for more details.
|
21 |
|
|
|
22 |
|
|
* You should have received a copy of the GNU General Public License
|
23 |
|
|
* along with this program; if not, write to the Free Software
|
24 |
|
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
25 |
|
|
*/
|
26 |
|
|
%>
|
27 |
3510
|
leinfelder
|
|
28 |
4235
|
leinfelder
|
<%@ include file="../../common/common-settings.jsp"%>
|
29 |
|
|
<%@ include file="../../common/configure-check.jsp"%>
|
30 |
4380
|
leinfelder
|
<%@page import="edu.ucsb.nceas.metacat.service.SessionService"%>
|
31 |
4387
|
leinfelder
|
<%@page import="java.util.Map"%>
|
32 |
3510
|
leinfelder
|
|
33 |
4387
|
leinfelder
|
|
34 |
3510
|
leinfelder
|
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
35 |
4387
|
leinfelder
|
<%@page import="java.util.Iterator"%>
|
36 |
4484
|
leinfelder
|
<%@page import="edu.ucsb.nceas.metacat.service.SessionService"%>
|
37 |
3510
|
leinfelder
|
<html>
|
38 |
|
|
<head>
|
39 |
|
|
<title>FIRST Data Repository</title>
|
40 |
|
|
<link rel="stylesheet" type="text/css"
|
41 |
4235
|
leinfelder
|
href="<%=STYLE_SKINS_URL%>/first/first.css"></link>
|
42 |
4388
|
leinfelder
|
<script language="Javascript" type="text/JavaScript"
|
43 |
|
|
src="<%=STYLE_COMMON_URL%>/prototype-1.5.1.1/prototype.js">
|
44 |
|
|
</script>
|
45 |
|
|
<script language="Javascript" type="text/JavaScript"
|
46 |
|
|
src="<%=STYLE_COMMON_URL%>/effects.js">
|
47 |
|
|
</script>
|
48 |
|
|
<script language="Javascript">
|
49 |
|
|
|
50 |
|
|
function highlight() {
|
51 |
|
|
//Effect.Pulsate('importantThings', { pulses: 1, duration: 2 });
|
52 |
|
|
//Effect.Fade('importantThings');
|
53 |
4392
|
leinfelder
|
new Effect.Highlight('importantThings', { startcolor: '#ffff99', endcolor: '#ffffff' });
|
54 |
|
|
//Effect.Shake('importantThings');
|
55 |
4388
|
leinfelder
|
}
|
56 |
|
|
</script>
|
57 |
|
|
|
58 |
3510
|
leinfelder
|
</head>
|
59 |
|
|
|
60 |
4388
|
leinfelder
|
<body onload="highlight()">
|
61 |
4387
|
leinfelder
|
<table width="100%" border="0" cellspacing="0" cellpadding="0">
|
62 |
4484
|
leinfelder
|
<tr>
|
63 |
|
|
<td width="75%" height="145" valign="middle" background="<%=STYLE_SKINS_URL%>/first/images/bkgrndgradient.gif">
|
64 |
|
|
<table width="1094" border="0" cellspacing="0" cellpadding="0">
|
65 |
|
|
<tr>
|
66 |
|
|
<td width="1012"><img src="<%=STYLE_SKINS_URL%>/first/images/first_logo.png" width="1012" height="133" /></td>
|
67 |
|
|
<td width="82" valign="top"><br />
|
68 |
|
|
<table width="63" border="0" cellspacing="0" cellpadding="0">
|
69 |
|
|
<tr>
|
70 |
|
|
<td> </td>
|
71 |
|
|
</tr>
|
72 |
|
|
<tr>
|
73 |
|
|
<td> </td>
|
74 |
|
|
</tr>
|
75 |
|
|
<tr>
|
76 |
|
|
<td> </td>
|
77 |
|
|
</tr>
|
78 |
|
|
</table>
|
79 |
|
|
</td>
|
80 |
|
|
</tr>
|
81 |
|
|
</table>
|
82 |
3510
|
leinfelder
|
</td>
|
83 |
4484
|
leinfelder
|
</tr>
|
84 |
|
|
<tr>
|
85 |
4536
|
leinfelder
|
<td height="48" valign="middle" align="center" bgcolor="#C8C4B9" background="<%=STYLE_SKINS_URL%>/first/images/navbarbackground.gif">
|
86 |
4484
|
leinfelder
|
<table width="780" border="0" cellspacing="0" cellpadding="0">
|
87 |
|
|
<tr>
|
88 |
4536
|
leinfelder
|
<td><a href="index.jsp" target="_top">Home</a></td>
|
89 |
|
|
<td><a href="http://www.first2.org/" target="_top">FIRST</a></td>
|
90 |
4484
|
leinfelder
|
<td><a href="about.jsp" target="_top">About</a></td>
|
91 |
4380
|
leinfelder
|
<%
|
92 |
4398
|
leinfelder
|
boolean loggedIn = SessionService.isSessionRegistered(request.getSession().getId());
|
93 |
|
|
String[] docids = null;
|
94 |
|
|
Map fields = null;
|
95 |
|
|
if (loggedIn) {
|
96 |
|
|
docids =
|
97 |
|
|
SessionService.getRegisteredSession(request.getSession().getId()).getDocumentCart().getDocids();
|
98 |
|
|
fields =
|
99 |
|
|
SessionService.getRegisteredSession(request.getSession().getId()).getDocumentCart().getFields();
|
100 |
|
|
%>
|
101 |
4484
|
leinfelder
|
<td>
|
102 |
4489
|
leinfelder
|
<a href="<%=SERVLET_URL%>?action=logout&qformat=first" target="_top">Logout</a>
|
103 |
4484
|
leinfelder
|
</td>
|
104 |
|
|
<td>
|
105 |
4398
|
leinfelder
|
<div id="importantThings">
|
106 |
|
|
<a href="cart.jsp" target="_top">
|
107 |
4536
|
leinfelder
|
Data Cart
|
108 |
4398
|
leinfelder
|
</a>
|
109 |
|
|
(Items: <%=docids.length %>, Fields: <%=fields.size() %>)
|
110 |
|
|
</div>
|
111 |
4484
|
leinfelder
|
<!-- for the cart status -->
|
112 |
|
|
<div style="display:none;">
|
113 |
|
|
<form id='cartForm'>
|
114 |
|
|
<%
|
115 |
|
|
for (int i = 0; i < docids.length; i++) {
|
116 |
|
|
%>
|
117 |
|
|
<input name="@packageId" value="<%=docids[i] %>" type="hidden">
|
118 |
|
|
<%} %>
|
119 |
|
|
</form>
|
120 |
|
|
</div>
|
121 |
4398
|
leinfelder
|
<!-- for use when downloading merged data -->
|
122 |
|
|
<div style="display:none;">
|
123 |
|
|
<form id='fieldForm'>
|
124 |
|
|
<%
|
125 |
|
|
if (loggedIn) {
|
126 |
|
|
Iterator fieldIter = fields.keySet().iterator();
|
127 |
|
|
while (fieldIter.hasNext()) {
|
128 |
|
|
String key = (String) fieldIter.next();
|
129 |
|
|
String value = (String) fields.get(key);
|
130 |
|
|
%>
|
131 |
|
|
<input type="hidden" name="<%=key %>" value="<%=value %>" />
|
132 |
|
|
<%
|
133 |
|
|
}
|
134 |
|
|
}
|
135 |
|
|
%>
|
136 |
|
|
</form>
|
137 |
|
|
</div>
|
138 |
4484
|
leinfelder
|
</td>
|
139 |
4398
|
leinfelder
|
<%
|
140 |
|
|
}
|
141 |
|
|
else {
|
142 |
4380
|
leinfelder
|
%>
|
143 |
4484
|
leinfelder
|
<td>
|
144 |
|
|
<a href="login.jsp" target="_top">Login</a>
|
145 |
|
|
</td>
|
146 |
4398
|
leinfelder
|
<%
|
147 |
|
|
}
|
148 |
|
|
%>
|
149 |
4484
|
leinfelder
|
</tr>
|
150 |
3510
|
leinfelder
|
</table>
|
151 |
4380
|
leinfelder
|
</td>
|
152 |
3510
|
leinfelder
|
</tr>
|
153 |
|
|
</table>
|
154 |
|
|
</body>
|
155 |
|
|
</html>
|