1 |
553
|
tao
|
<?xml version="1.0"?>
|
2 |
|
|
<!--
|
3 |
|
|
* '$RCSfile$'
|
4 |
|
|
* Authors: Matthew Brooke
|
5 |
|
|
* Copyright: 2000 Regents of the University of California and the
|
6 |
|
|
* National Center for Ecological Analysis and Synthesis
|
7 |
|
|
* For Details: http://www.nceas.ucsb.edu/
|
8 |
|
|
*
|
9 |
|
|
* '$Author$'
|
10 |
|
|
* '$Date$'
|
11 |
|
|
* '$Revision$'
|
12 |
|
|
*
|
13 |
|
|
* This program is free software; you can redistribute it and/or modify
|
14 |
|
|
* it under the terms of the GNU General Public License as published by
|
15 |
|
|
* the Free Software Foundation; either version 2 of the License, or
|
16 |
|
|
* (at your option) any later version.
|
17 |
|
|
*
|
18 |
|
|
* This program is distributed in the hope that it will be useful,
|
19 |
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
20 |
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
21 |
|
|
* GNU General Public License for more details.
|
22 |
|
|
*
|
23 |
|
|
* You should have received a copy of the GNU General Public License
|
24 |
|
|
* along with this program; if not, write to the Free Software
|
25 |
|
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
26 |
|
|
*
|
27 |
|
|
* This is an XSLT (http://www.w3.org/TR/xslt) stylesheet designed to
|
28 |
|
|
* convert an XML file that is valid with respect to the eml-variable.dtd
|
29 |
|
|
* module of the Ecological Metadata Language (EML) into an HTML format
|
30 |
|
|
* suitable for rendering with modern web browsers.
|
31 |
|
|
-->
|
32 |
|
|
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
|
33 |
|
|
|
34 |
|
|
<xsl:output method="html" encoding="iso-8859-1"/>
|
35 |
|
|
|
36 |
1640
|
tao
|
|
37 |
|
|
<xsl:template name="project">
|
38 |
|
|
<xsl:param name="projectfirstColStyle"/>
|
39 |
1696
|
tao
|
<table xsl:use-attribute-sets="cellspacing" class="tabledefault" width="100%">
|
40 |
1640
|
tao
|
<xsl:choose>
|
41 |
|
|
<xsl:when test="references!=''">
|
42 |
|
|
<xsl:variable name="ref_id" select="references"/>
|
43 |
|
|
<xsl:variable name="references" select="$ids[@id=$ref_id]" />
|
44 |
|
|
<xsl:for-each select="$references">
|
45 |
1686
|
tao
|
<xsl:call-template name="projectcommon">
|
46 |
1640
|
tao
|
<xsl:with-param name="projectfirstColStyle" select="$projectfirstColStyle"/>
|
47 |
|
|
</xsl:call-template>
|
48 |
|
|
</xsl:for-each>
|
49 |
|
|
</xsl:when>
|
50 |
|
|
<xsl:otherwise>
|
51 |
1686
|
tao
|
<xsl:call-template name="projectcommon">
|
52 |
1640
|
tao
|
<xsl:with-param name="projectfirstColStyle" select="$projectfirstColStyle"/>
|
53 |
|
|
</xsl:call-template>
|
54 |
|
|
</xsl:otherwise>
|
55 |
|
|
</xsl:choose>
|
56 |
|
|
</table>
|
57 |
553
|
tao
|
</xsl:template>
|
58 |
1640
|
tao
|
|
59 |
|
|
|
60 |
|
|
|
61 |
|
|
<xsl:template name="projectcommon">
|
62 |
|
|
<xsl:param name="projectfirstColStyle"/>
|
63 |
|
|
<xsl:call-template name="projecttitle">
|
64 |
|
|
<xsl:with-param name="projectfirstColStyle" select="$projectfirstColStyle"/>
|
65 |
|
|
</xsl:call-template>
|
66 |
|
|
<xsl:call-template name="projectpersonnel">
|
67 |
|
|
<xsl:with-param name="projectfirstColStyle" select="$projectfirstColStyle"/>
|
68 |
|
|
</xsl:call-template>
|
69 |
|
|
<xsl:call-template name="projectabstract">
|
70 |
|
|
<xsl:with-param name="projectfirstColStyle" select="$projectfirstColStyle"/>
|
71 |
|
|
</xsl:call-template>
|
72 |
|
|
<xsl:call-template name="projectfunding">
|
73 |
|
|
<xsl:with-param name="projectfirstColStyle" select="$projectfirstColStyle"/>
|
74 |
|
|
</xsl:call-template>
|
75 |
|
|
<xsl:call-template name="projectstudyareadescription">
|
76 |
|
|
<xsl:with-param name="projectfirstColStyle" select="$projectfirstColStyle"/>
|
77 |
|
|
</xsl:call-template>
|
78 |
|
|
<xsl:call-template name="projectdesigndescription">
|
79 |
|
|
<xsl:with-param name="projectfirstColStyle" select="$projectfirstColStyle"/>
|
80 |
|
|
</xsl:call-template>
|
81 |
|
|
<xsl:call-template name="projectrelatedproject">
|
82 |
|
|
<xsl:with-param name="projectfirstColStyle" select="$projectfirstColStyle"/>
|
83 |
|
|
</xsl:call-template>
|
84 |
553
|
tao
|
</xsl:template>
|
85 |
|
|
|
86 |
1640
|
tao
|
|
87 |
|
|
|
88 |
|
|
<xsl:template name="projecttitle">
|
89 |
|
|
<xsl:param name="projectfirstColStyle"/>
|
90 |
|
|
<xsl:for-each select="title">
|
91 |
|
|
<tr><td width="{$firstColWidth}" class="{$projectfirstColStyle}">
|
92 |
|
|
Title:
|
93 |
|
|
</td>
|
94 |
|
|
<td width="{$secondColWidth}" class="{$secondColStyle}" >
|
95 |
|
|
<xsl:value-of select="../title"/>
|
96 |
|
|
</td>
|
97 |
|
|
</tr>
|
98 |
|
|
</xsl:for-each>
|
99 |
553
|
tao
|
</xsl:template>
|
100 |
1640
|
tao
|
|
101 |
|
|
|
102 |
|
|
|
103 |
|
|
<xsl:template name="projectpersonnel">
|
104 |
|
|
<xsl:param name="projectfirstColStyle"/>
|
105 |
|
|
<tr><td width="{$firstColWidth}" class="{$projectfirstColStyle}">
|
106 |
|
|
Personnel:
|
107 |
|
|
</td>
|
108 |
1715
|
tao
|
<td width="{$secondColWidth}">
|
109 |
|
|
<table xsl:use-attribute-sets="cellspacing" width="100%">
|
110 |
|
|
<xsl:for-each select="personnel">
|
111 |
|
|
<tr><td colspan="2">
|
112 |
|
|
<xsl:call-template name="party">
|
113 |
|
|
<xsl:with-param name="partyfirstColStyle" select="$projectfirstColStyle"/>
|
114 |
|
|
</xsl:call-template>
|
115 |
|
|
</td></tr>
|
116 |
|
|
<xsl:for-each select="role">
|
117 |
|
|
<tr><td width="{$firstColWidth}" class="{$projectfirstColStyle}">
|
118 |
|
|
Role:
|
119 |
|
|
</td>
|
120 |
|
|
<td width="{$secondColWidth}">
|
121 |
|
|
<table xsl:use-attribute-sets="cellspacing" class="tableparty" width="100%">
|
122 |
|
|
<tr>
|
123 |
|
|
<td width="100%" class="{$secondColStyle}">
|
124 |
|
|
<xsl:value-of select="."/>
|
125 |
|
|
</td>
|
126 |
|
|
</tr>
|
127 |
|
|
</table>
|
128 |
|
|
</td>
|
129 |
|
|
</tr>
|
130 |
|
|
</xsl:for-each>
|
131 |
|
|
</xsl:for-each>
|
132 |
|
|
</table>
|
133 |
|
|
</td>
|
134 |
1640
|
tao
|
</tr>
|
135 |
553
|
tao
|
</xsl:template>
|
136 |
1640
|
tao
|
|
137 |
|
|
|
138 |
|
|
<xsl:template name="projectabstract">
|
139 |
|
|
<xsl:param name="projectfirstColStyle"/>
|
140 |
|
|
<xsl:for-each select="abstract">
|
141 |
|
|
<tr><td width="{$firstColWidth}" class="{$projectfirstColStyle}">
|
142 |
|
|
Abstract:
|
143 |
|
|
</td>
|
144 |
1706
|
tao
|
<td width="{$secondColWidth}">
|
145 |
1691
|
tao
|
<xsl:call-template name="text">
|
146 |
|
|
<xsl:with-param name="textfirstColStyle" select="$projectfirstColStyle"/>
|
147 |
|
|
</xsl:call-template>
|
148 |
1640
|
tao
|
</td>
|
149 |
|
|
</tr>
|
150 |
1691
|
tao
|
</xsl:for-each>
|
151 |
553
|
tao
|
</xsl:template>
|
152 |
1640
|
tao
|
|
153 |
|
|
<xsl:template name="projectfunding">
|
154 |
|
|
<xsl:param name="projectfirstColStyle"/>
|
155 |
|
|
<xsl:for-each select="funding">
|
156 |
|
|
<tr><td width="{$firstColWidth}" class="{$projectfirstColStyle}">
|
157 |
|
|
Funding:
|
158 |
|
|
</td>
|
159 |
1706
|
tao
|
<td width="{$secondColWidth}">
|
160 |
1691
|
tao
|
<xsl:call-template name="text">
|
161 |
|
|
<xsl:with-param name="textfirstColStyle" select="$projectfirstColStyle"/>
|
162 |
|
|
</xsl:call-template>
|
163 |
1640
|
tao
|
</td>
|
164 |
|
|
</tr>
|
165 |
|
|
</xsl:for-each>
|
166 |
553
|
tao
|
</xsl:template>
|
167 |
1640
|
tao
|
|
168 |
|
|
|
169 |
|
|
|
170 |
|
|
<xsl:template name="projectstudyareadescription">
|
171 |
|
|
<xsl:param name="projectfirstColStyle"/>
|
172 |
|
|
<xsl:for-each select="studyAreaDescription">
|
173 |
|
|
<tr><td width="{$firstColWidth}" class="{$projectfirstColStyle}">
|
174 |
1691
|
tao
|
<xsl:text>Study Area:</xsl:text>
|
175 |
1640
|
tao
|
</td>
|
176 |
1706
|
tao
|
<td width="{$secondColWidth}">
|
177 |
1696
|
tao
|
<table xsl:use-attribute-sets="cellspacing" class="tabledefault" width="100%">
|
178 |
1691
|
tao
|
<xsl:for-each select="descriptor">
|
179 |
|
|
<xsl:for-each select="descriptorValue">
|
180 |
|
|
<tr><td width="{$firstColWidth}" class="{$projectfirstColStyle}">
|
181 |
|
|
<xsl:value-of select="../@name"/>
|
182 |
|
|
</td>
|
183 |
|
|
<td width="{$secondColWidth}" class="{$secondColStyle}">
|
184 |
1726
|
tao
|
<xsl:choose>
|
185 |
|
|
<xsl:when test="./@citableClassificationSystem">
|
186 |
|
|
<xsl:value-of select="."/> <xsl:value-of select="./@name_or_id"/>
|
187 |
|
|
</xsl:when>
|
188 |
|
|
<xsl:otherwise>
|
189 |
|
|
<xsl:value-of select="."/> <xsl:value-of select="./@name_or_id"/> (No Citable Classification System)
|
190 |
|
|
</xsl:otherwise>
|
191 |
|
|
</xsl:choose>
|
192 |
1691
|
tao
|
</td>
|
193 |
|
|
</tr>
|
194 |
|
|
</xsl:for-each>
|
195 |
|
|
<xsl:for-each select="citation">
|
196 |
|
|
<tr><td width="{$firstColWidth}" class="{$projectfirstColStyle}">
|
197 |
|
|
Citation:
|
198 |
|
|
</td>
|
199 |
1706
|
tao
|
<td width="{$secondColWidth}">
|
200 |
1691
|
tao
|
<xsl:call-template name="citation">
|
201 |
|
|
<xsl:with-param name="citationfirstColStyle" select="projectfirstColStyle"/>
|
202 |
|
|
</xsl:call-template>
|
203 |
|
|
</td>
|
204 |
|
|
</tr>
|
205 |
|
|
</xsl:for-each>
|
206 |
|
|
</xsl:for-each>
|
207 |
|
|
</table>
|
208 |
1640
|
tao
|
</td>
|
209 |
|
|
</tr>
|
210 |
1691
|
tao
|
|
211 |
1640
|
tao
|
<xsl:for-each select="citation">
|
212 |
|
|
<tr><td width="{$firstColWidth}" class="{$projectfirstColStyle}">
|
213 |
1691
|
tao
|
Study Area Citation:
|
214 |
1640
|
tao
|
</td>
|
215 |
1706
|
tao
|
<td width="{$secondColWidth}">
|
216 |
1691
|
tao
|
<xsl:call-template name="citation">
|
217 |
|
|
<xsl:with-param name="citationfirstColStyle" select="projectfirstColStyle"/>
|
218 |
|
|
</xsl:call-template>
|
219 |
|
|
</td>
|
220 |
1640
|
tao
|
</tr>
|
221 |
553
|
tao
|
</xsl:for-each>
|
222 |
1640
|
tao
|
|
223 |
|
|
<xsl:for-each select="coverage">
|
224 |
|
|
<tr><td width="{$firstColWidth}" class="{$projectfirstColStyle}">
|
225 |
1691
|
tao
|
Study Area Coverage:
|
226 |
1640
|
tao
|
</td>
|
227 |
1706
|
tao
|
<td width="{$secondColWidth}">
|
228 |
1640
|
tao
|
<xsl:call-template name="coverage"/>
|
229 |
|
|
</td>
|
230 |
|
|
</tr>
|
231 |
1691
|
tao
|
</xsl:for-each>
|
232 |
1640
|
tao
|
</xsl:for-each>
|
233 |
|
|
</xsl:template>
|
234 |
|
|
|
235 |
|
|
|
236 |
|
|
|
237 |
|
|
<xsl:template name="projectdesigndescription">
|
238 |
|
|
<xsl:param name="projectfirstColStyle"/>
|
239 |
|
|
<xsl:for-each select="designDescription">
|
240 |
|
|
<xsl:for-each select="description">
|
241 |
|
|
<tr><td width="{$firstColWidth}" class="{$projectfirstColStyle}">
|
242 |
|
|
Design Description:
|
243 |
|
|
</td>
|
244 |
1706
|
tao
|
<td width="{$secondColWidth}">
|
245 |
1640
|
tao
|
<xsl:call-template name="text"/>
|
246 |
|
|
</td>
|
247 |
|
|
</tr>
|
248 |
553
|
tao
|
</xsl:for-each>
|
249 |
1640
|
tao
|
<xsl:for-each select="citation">
|
250 |
|
|
<tr><td width="{$firstColWidth}" class="{$projectfirstColStyle}">
|
251 |
|
|
Design Citation:
|
252 |
|
|
</td>
|
253 |
1706
|
tao
|
<td width="{$secondColWidth}" >
|
254 |
1640
|
tao
|
<xsl:call-template name="citation"/>
|
255 |
|
|
</td>
|
256 |
|
|
</tr>
|
257 |
|
|
</xsl:for-each>
|
258 |
|
|
</xsl:for-each>
|
259 |
553
|
tao
|
</xsl:template>
|
260 |
|
|
|
261 |
1640
|
tao
|
|
262 |
|
|
|
263 |
|
|
<xsl:template name="projectrelatedproject">
|
264 |
|
|
<xsl:param name="projectfirstColStyle"/>
|
265 |
|
|
<xsl:for-each select="relatedProject">
|
266 |
|
|
<tr><td width="{$firstColWidth}" class="{$projectfirstColStyle}">
|
267 |
|
|
Related Project:
|
268 |
|
|
</td>
|
269 |
1706
|
tao
|
<td width="{$secondColWidth}">
|
270 |
1691
|
tao
|
<xsl:call-template name="project">
|
271 |
|
|
<xsl:with-param name="projectfirstColStyle" select="$projectfirstColStyle"/>
|
272 |
|
|
</xsl:call-template>
|
273 |
1640
|
tao
|
</td>
|
274 |
|
|
</tr>
|
275 |
|
|
</xsl:for-each>
|
276 |
553
|
tao
|
</xsl:template>
|
277 |
1640
|
tao
|
|
278 |
553
|
tao
|
|
279 |
|
|
</xsl:stylesheet>
|