1
|
<?xml version="1.0"?>
|
2
|
<!--
|
3
|
* marine.xsl
|
4
|
*
|
5
|
* Authors: Matt Jones, Chad Berkley
|
6
|
* Copyright: 2000 Regents of the University of California and the
|
7
|
* National Center for Ecological Analysis and Synthesis
|
8
|
* For Details: http://www.nceas.ucsb.edu/
|
9
|
* Created: 2000 July 20
|
10
|
* File Info: '$Id: marine.xsl 318 2000-08-04 15:32:40Z berkley $'
|
11
|
*
|
12
|
* This is an XSLT (http://www.w3.org/TR/xslt) stylesheet designed to
|
13
|
* convert an XML file showing the resultset of a query
|
14
|
* into an HTML format suitable for rendering with modern web browsers.
|
15
|
* This stylesheet formats .
|
16
|
-->
|
17
|
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
|
18
|
|
19
|
<xsl:output method="html"/>
|
20
|
|
21
|
<xsl:template match="/">
|
22
|
<html>
|
23
|
<head>
|
24
|
<link rel="stylesheet" type="text/css" href="/xmltodb/lib/marine/rowcol.css" />
|
25
|
</head>
|
26
|
<body class="emlbody">
|
27
|
<script language="JavaScript">
|
28
|
function gotoNceas()
|
29
|
{
|
30
|
window.location="http://www.nceas.ucsb.edu";
|
31
|
}
|
32
|
</script>
|
33
|
<a name="top" />
|
34
|
<table width="100%">
|
35
|
<tr>
|
36
|
<td align="left" valign="top">
|
37
|
<form action="http://alpha.nceas.ucsb.edu/servlets/marineServlet#browse"
|
38
|
method="POST">
|
39
|
<input type="hidden" name="action" value="squery" />
|
40
|
<input type="hidden" name="query" value="" />
|
41
|
<input type="hidden" name="qformat" value="html" />
|
42
|
<input type="hidden" name="operator" value="UNION" />
|
43
|
<input type="hidden" name="anyfield" value="%" />
|
44
|
<input type="submit" value="Browse the Database" size="15" />
|
45
|
</form>
|
46
|
</td>
|
47
|
<td align="center" valign="bottom">
|
48
|
<img src="/xmltodb/lib/marine/logo-line.gif" alt="NCEAS Logo" onClick="gotoNceas()" />
|
49
|
</td>
|
50
|
<td align="right" valign="top">
|
51
|
<form action="http://alpha.nceas.ucsb.edu/servlets/marineServlet#browse"
|
52
|
method="POST">
|
53
|
Quick Search: <input type="text" name="query" size="10" />
|
54
|
<input type="hidden" name="action" value="query" />
|
55
|
<input type="hidden" name="qformat" value="html" />
|
56
|
<input type="hidden" name="operator" value="UNION" />
|
57
|
</form>
|
58
|
</td>
|
59
|
</tr>
|
60
|
</table>
|
61
|
|
62
|
<hr />
|
63
|
|
64
|
<center><h1>MARINE Query Interface</h1></center>
|
65
|
<font size="2">
|
66
|
<p class="intro">
|
67
|
This page is used to query information for
|
68
|
<a href="http://www.mms.gov/omm/pacific/enviro/mint.htm">MARINE</a> scientists from
|
69
|
the NCEAS Ecological Metadata Database. For more information on
|
70
|
this project, please read the
|
71
|
<a href="https://www2.nceas.ucsb.edu/admin/db/web.ppage?projid_in=2841">
|
72
|
proposal abstract</a>.
|
73
|
</p>
|
74
|
|
75
|
<p class="intro">
|
76
|
Each step below contains several fields relating to a part of the dataset.
|
77
|
You may also browse
|
78
|
the entire database by simply clicking the browse link at the top of the page.
|
79
|
Clicking on the buttons next to each data line will give you more
|
80
|
information about the dataset or allow you to download the entire dataset.
|
81
|
Please note some fields in the query forms will not be pertinent to your dataset.
|
82
|
If this is the case, simply leave any field blank to omit it from the searching.
|
83
|
</p>
|
84
|
|
85
|
<p class="intro">
|
86
|
Note that the wildcard character is a percent sign (%). It may be used in any
|
87
|
field to denote "any" value. For example, the query "do%" would return "document"
|
88
|
or "dog" or "domino" or "dolphin", etc. Placing a single percent sign in a field
|
89
|
will return any document that contains that field. Placing a percent sign in
|
90
|
the "Any Field" field is equivalent to browsing the database (i.e. it will return
|
91
|
every document).
|
92
|
</p>
|
93
|
</font>
|
94
|
|
95
|
<form action="http://alpha.nceas.ucsb.edu/servlets/marineServlet#browse"
|
96
|
method="POST">
|
97
|
|
98
|
<table width="100%" border="1">
|
99
|
<tr>
|
100
|
<td valign="bottom" width = "25">
|
101
|
<img src="http://alpha.nceas.ucsb.edu/xmltodb/lib/marine/step1.jpg" />
|
102
|
</td>
|
103
|
<td>
|
104
|
<h4>Keywords and Title</h4>
|
105
|
<p>
|
106
|
<font size="2">
|
107
|
Enter any keywords that might partain to the dataset you are looking for.
|
108
|
The "Any Field" text box will search for any field in any document for
|
109
|
the text you provide. The title and alternate title will search for text
|
110
|
in the title or alternate title fields of a document only. Fields left
|
111
|
blank will not be used in the search criteria.
|
112
|
</font></p>
|
113
|
</td>
|
114
|
</tr>
|
115
|
</table>
|
116
|
|
117
|
<table width="100%">
|
118
|
<tr>
|
119
|
<td>Title:</td>
|
120
|
<td>
|
121
|
<input type="text" name="title" size="15">
|
122
|
<xsl:attribute name="value">
|
123
|
<xsl:value-of select="resultset/query/title" />
|
124
|
</xsl:attribute>
|
125
|
</input>
|
126
|
</td>
|
127
|
<td>Any Field:</td>
|
128
|
<td>
|
129
|
<input type="text" name="anyfield" size="15">
|
130
|
<xsl:attribute name="value">
|
131
|
<xsl:value-of select="resultset/query/anyfield" />
|
132
|
</xsl:attribute>
|
133
|
</input>
|
134
|
</td>
|
135
|
</tr>
|
136
|
<tr>
|
137
|
<td>Alternate Title:</td>
|
138
|
<td>
|
139
|
<input type="text" name="alttitle" size="15">
|
140
|
<xsl:attribute name="value">
|
141
|
<xsl:value-of select="resultset/query/alttitle" />
|
142
|
</xsl:attribute>
|
143
|
</input>
|
144
|
</td>
|
145
|
<td>Keywords:</td>
|
146
|
<td>
|
147
|
<input type="text" name="keyword" size="15">
|
148
|
<xsl:attribute name="value">
|
149
|
<xsl:value-of select="resultset/query/keyword" />
|
150
|
</xsl:attribute>
|
151
|
</input>
|
152
|
</td>
|
153
|
</tr>
|
154
|
</table>
|
155
|
|
156
|
<table width="100%" border="1">
|
157
|
<tr>
|
158
|
<td valign="bottom" width="25">
|
159
|
<img src="http://alpha.nceas.ucsb.edu/xmltodb/lib/marine/step2.jpg" />
|
160
|
</td>
|
161
|
<td>
|
162
|
<h4>Dataset Owner Information</h4>
|
163
|
<p>
|
164
|
<font size="2">
|
165
|
Enter data about the owner of the dataset. There may be more than one
|
166
|
owner of any given dataset. Any field(s) left blank will not be used
|
167
|
in the search criteria.
|
168
|
</font>
|
169
|
</p>
|
170
|
</td>
|
171
|
</tr>
|
172
|
</table>
|
173
|
<table width="100%">
|
174
|
<tr>
|
175
|
<td>First Name:</td>
|
176
|
<td>
|
177
|
<input type="text" name="given_name" size="15">
|
178
|
<xsl:attribute name="value">
|
179
|
<xsl:value-of select="resultset/query/given_name" />
|
180
|
</xsl:attribute>
|
181
|
</input>
|
182
|
</td>
|
183
|
<td>Last Name:</td>
|
184
|
<td> <!-- <input type="text" name="surname" /> -->
|
185
|
<input type="text" name="surname" size="15">
|
186
|
<xsl:attribute name="value">
|
187
|
<xsl:value-of select="resultset/query/surname" />
|
188
|
</xsl:attribute>
|
189
|
</input>
|
190
|
</td>
|
191
|
</tr>
|
192
|
<tr>
|
193
|
<td>Organization:</td>
|
194
|
<td>
|
195
|
<input type="text" name="organizationName" size="15">
|
196
|
<xsl:attribute name="value">
|
197
|
<xsl:value-of select="resultset/query/organizationName" />
|
198
|
</xsl:attribute>
|
199
|
</input>
|
200
|
</td>
|
201
|
<td>Email Address:</td>
|
202
|
<td>
|
203
|
<input type="text" name="electronicMailAddress" size="15">
|
204
|
<xsl:attribute name="value">
|
205
|
<xsl:value-of select="resultset/query/electronicMailAddress" />
|
206
|
</xsl:attribute>
|
207
|
</input>
|
208
|
</td>
|
209
|
</tr>
|
210
|
</table>
|
211
|
|
212
|
<table width="100%" border="1">
|
213
|
<tr>
|
214
|
<td valign="bottom" width="25">
|
215
|
<img src="http://alpha.nceas.ucsb.edu/xmltodb/lib/marine/step3.jpg" />
|
216
|
</td>
|
217
|
<td>
|
218
|
<h4>Query the Database</h4>
|
219
|
<p>
|
220
|
<font size="2">
|
221
|
Click the Query button to submit your query. The results will be
|
222
|
displayed below under the heading "Results".
|
223
|
</font>
|
224
|
</p>
|
225
|
</td>
|
226
|
</tr>
|
227
|
</table>
|
228
|
<input type="hidden" name="action" value="squery" />
|
229
|
<input type="hidden" name="query" value="" />
|
230
|
<input type="hidden" name="qformat" value="html" />
|
231
|
<input type="hidden" name="operator" value="UNION" />
|
232
|
|
233
|
<input type="submit" value="Query" />
|
234
|
<input type="reset" value="Clear Form" />
|
235
|
|
236
|
</form>
|
237
|
|
238
|
<a name="browse" />
|
239
|
<font size="3"><xsl:number value="count(resultset/document)" /> documents found.</font>
|
240
|
<!-- This tests to see if there are returned documents,
|
241
|
if there are not then don't show the query results
|
242
|
-->
|
243
|
<xsl:if test="count(resultset/document) > 0">
|
244
|
|
245
|
<center>
|
246
|
<u><h2>Results</h2></u>
|
247
|
</center>
|
248
|
|
249
|
<form action="/servlets/marineServlet" method="POST">
|
250
|
<input type="hidden" name="action" value="getdocument"/>
|
251
|
|
252
|
<table width="100%">
|
253
|
<tr class="rowodd">
|
254
|
<th> </th>
|
255
|
<th><xsl:text>Title</xsl:text></th>
|
256
|
<th><xsl:text>Owner</xsl:text></th>
|
257
|
<th><xsl:text>Organization</xsl:text></th>
|
258
|
<th><xsl:text>Creation Date</xsl:text></th>
|
259
|
<th><xsl:text>Last Updated</xsl:text></th>
|
260
|
</tr>
|
261
|
|
262
|
|
263
|
|
264
|
<xsl:for-each select="resultset/document">
|
265
|
<xsl:sort select="doctitle"/>
|
266
|
<tr valign="top">
|
267
|
<xsl:attribute name="class">
|
268
|
<xsl:choose>
|
269
|
<xsl:when test="position() mod 2 = 1">rowwhite</xsl:when>
|
270
|
<xsl:when test="position() mod 2 = 0">rowlight</xsl:when>
|
271
|
</xsl:choose>
|
272
|
</xsl:attribute>
|
273
|
|
274
|
<td>
|
275
|
<input border="0" type="image">
|
276
|
<xsl:attribute name="src">
|
277
|
<xsl:choose>
|
278
|
<xsl:when test="position()
|
279
|
mod 2 = 1">/xmltodb/lib/marine/whiteMenu.jpg</xsl:when>
|
280
|
<xsl:when test="position()
|
281
|
mod 2 = 0">/xmltodb/lib/marine/blueMenu.jpg</xsl:when>
|
282
|
</xsl:choose>
|
283
|
</xsl:attribute>
|
284
|
<xsl:attribute name="name">
|
285
|
<xsl:value-of select="./docid"/>
|
286
|
</xsl:attribute>
|
287
|
</input>
|
288
|
</td>
|
289
|
<td><xsl:value-of select="./doctitle"/>
|
290
|
|
291
|
<xsl:text> </xsl:text>
|
292
|
</td>
|
293
|
<td><xsl:value-of select="./givenName" />
|
294
|
<xsl:text> </xsl:text>
|
295
|
<xsl:value-of select="./surName" />
|
296
|
<xsl:text> </xsl:text>
|
297
|
</td>
|
298
|
<td><xsl:value-of select="./organizationName" />
|
299
|
<xsl:text> </xsl:text>
|
300
|
</td>
|
301
|
<td>
|
302
|
<xsl:value-of select="./date_created" />
|
303
|
<xsl:text> </xsl:text>
|
304
|
</td>
|
305
|
<td>
|
306
|
<xsl:value-of select="./date_updated" />
|
307
|
<xsl:text> </xsl:text>
|
308
|
</td>
|
309
|
</tr>
|
310
|
</xsl:for-each>
|
311
|
</table>
|
312
|
</form>
|
313
|
|
314
|
<h3><a href="#top">New Query</a></h3>
|
315
|
|
316
|
</xsl:if>
|
317
|
|
318
|
</body>
|
319
|
</html>
|
320
|
</xsl:template>
|
321
|
|
322
|
</xsl:stylesheet>
|