Revision 5713
Added by ben leinfelder over 13 years ago
eml-resource.xsl | ||
---|---|---|
33 | 33 |
<!--<xsl:import href="eml-party.xsl"/> |
34 | 34 |
<xsl:import href="eml-distribution.xsl"/> |
35 | 35 |
<xsl:import href="eml-coverage.xsl"/>--> |
36 |
<xsl:output method="html" encoding="iso-8859-1"
|
|
36 |
<xsl:output method="html" encoding="UTF-8"
|
|
37 | 37 |
doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN" |
38 | 38 |
doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" |
39 | 39 |
indent="yes" /> |
... | ... | |
43 | 43 |
<xsl:param name="resfirstColStyle"/> |
44 | 44 |
<xsl:param name="ressubHeaderStyle"/> |
45 | 45 |
<xsl:param name="creator">Data Set Owner(s):</xsl:param> |
46 |
|
|
47 |
<!-- |
|
48 |
<xsl:for-each select="alternateIdentifier"> |
|
49 |
<xsl:call-template name="resourcealternateIdentifier"> |
|
50 |
<xsl:with-param name="resfirstColStyle" select="$resfirstColStyle"/> |
|
51 |
</xsl:call-template> |
|
52 |
</xsl:for-each> |
|
53 |
|
|
54 |
<xsl:for-each select="shortName"> |
|
55 |
<xsl:call-template name="resourceshortName"> |
|
56 |
<xsl:with-param name="resfirstColStyle" select="$resfirstColStyle"/> |
|
57 |
</xsl:call-template> |
|
58 |
</xsl:for-each> |
|
59 |
|
|
60 |
<xsl:for-each select="title"> |
|
61 |
<xsl:call-template name="resourcetitle"> |
|
62 |
<xsl:with-param name="resfirstColStyle" select="$resfirstColStyle"/> |
|
63 |
<xsl:with-param name="ressubHeaderStyle" select="$ressubHeaderStyle"/> |
|
64 |
</xsl:call-template> |
|
65 |
</xsl:for-each> |
|
66 |
|
|
67 |
<xsl:for-each select="pubDate"> |
|
68 |
<xsl:call-template name="resourcepubDate" > |
|
69 |
<xsl:with-param name="resfirstColStyle" select="$resfirstColStyle"/> |
|
70 |
</xsl:call-template> |
|
71 |
</xsl:for-each> |
|
72 |
|
|
73 |
<xsl:for-each select="language"> |
|
74 |
<xsl:call-template name="resourcelanguage" > |
|
75 |
<xsl:with-param name="resfirstColStyle" select="$resfirstColStyle"/> |
|
76 |
</xsl:call-template> |
|
77 |
</xsl:for-each> |
|
78 |
|
|
79 |
<xsl:for-each select="series"> |
|
80 |
<xsl:call-template name="resourceseries" > |
|
81 |
<xsl:with-param name="resfirstColStyle" select="$resfirstColStyle"/> |
|
82 |
</xsl:call-template> |
|
83 |
</xsl:for-each> |
|
84 |
|
|
85 |
<xsl:if test="creator"> |
|
86 |
<tr> |
|
87 |
<td class="{$ressubHeaderStyle}" colspan="2"> |
|
88 |
<h3><xsl:value-of select="$creator"/></h3> |
|
89 |
</td> |
|
90 |
</tr> |
|
91 |
</xsl:if> |
|
92 |
<xsl:for-each select="creator"> |
|
93 |
<xsl:call-template name="resourcecreator"> |
|
94 |
<xsl:with-param name="resfirstColStyle" select="$resfirstColStyle"/> |
|
95 |
</xsl:call-template> |
|
96 |
</xsl:for-each> |
|
97 |
|
|
98 |
<xsl:if test="metadataProvider"> |
|
99 |
<tr><td class="{$ressubHeaderStyle}" colspan="2"> |
|
100 |
<xsl:text>Metadata Provider(s):</xsl:text> |
|
101 |
</td></tr> |
|
102 |
</xsl:if> |
|
103 |
<xsl:for-each select="metadataProvider"> |
|
104 |
<xsl:call-template name="resourcemetadataProvider"> |
|
105 |
<xsl:with-param name="resfirstColStyle" select="$resfirstColStyle"/> |
|
106 |
</xsl:call-template> |
|
107 |
</xsl:for-each> |
|
108 |
|
|
109 |
<xsl:if test="associatedParty"> |
|
110 |
<tr> |
|
111 |
<td class="{$ressubHeaderStyle}" colspan="2"> |
|
112 |
<h3><xsl:text>Associated Parties:</xsl:text></h3> |
|
113 |
</td> |
|
114 |
</tr> |
|
115 |
</xsl:if> |
|
116 |
<xsl:for-each select="associatedParty"> |
|
117 |
<xsl:call-template name="resourceassociatedParty"> |
|
118 |
<xsl:with-param name="resfirstColStyle" select="$resfirstColStyle"/> |
|
119 |
</xsl:call-template> |
|
120 |
</xsl:for-each> |
|
121 |
|
|
122 |
<xsl:for-each select="abstract"> |
|
123 |
<xsl:call-template name="resourceabstract" > |
|
124 |
<xsl:with-param name="resfirstColStyle" select="$resfirstColStyle"/> |
|
125 |
<xsl:with-param name="ressubHeaderStyle" select="$ressubHeaderStyle"/> |
|
126 |
</xsl:call-template> |
|
127 |
</xsl:for-each> |
|
128 |
|
|
129 |
<xsl:if test="keywordSet"> |
|
130 |
<tr><td class="{$ressubHeaderStyle}" colspan="2"> |
|
131 |
<xsl:text>Keywords:</xsl:text></td></tr> |
|
132 |
</xsl:if> |
|
133 |
<xsl:for-each select="keywordSet"> |
|
134 |
<xsl:call-template name="resourcekeywordSet" > |
|
135 |
<xsl:with-param name="resfirstColStyle" select="$resfirstColStyle"/> |
|
136 |
</xsl:call-template> |
|
137 |
</xsl:for-each> |
|
138 |
|
|
139 |
<xsl:for-each select="additionalInfo"> |
|
140 |
<xsl:call-template name="resourceadditionalInfo" > |
|
141 |
<xsl:with-param name="resfirstColStyle" select="$resfirstColStyle"/> |
|
142 |
<xsl:with-param name="ressubHeaderStyle" select="$ressubHeaderStyle"/> |
|
143 |
</xsl:call-template> |
|
144 |
</xsl:for-each> |
|
145 |
|
|
146 |
<xsl:for-each select="intellectualRights"> |
|
147 |
<xsl:call-template name="resourceintellectualRights" > |
|
148 |
<xsl:with-param name="resfirstColStyle" select="$resfirstColStyle"/> |
|
149 |
<xsl:with-param name="ressubHeaderStyle" select="$ressubHeaderStyle"/> |
|
150 |
</xsl:call-template> |
|
151 |
</xsl:for-each> |
|
152 |
|
|
153 |
<xsl:for-each select="distribution"> |
|
154 |
<xsl:call-template name="resourcedistribution"> |
|
155 |
<xsl:with-param name="resfirstColStyle" select="$resfirstColStyle"/> |
|
156 |
<xsl:with-param name="ressubHeaderStyle" select="$ressubHeaderStyle"/> |
|
157 |
<xsl:with-param name="index" select="position()"/> |
|
158 |
<xsl:with-param name="docid" select="$docid"/> |
|
159 |
</xsl:call-template> |
|
160 |
</xsl:for-each> |
|
161 |
|
|
162 |
<xsl:for-each select="coverage"> |
|
163 |
<xsl:call-template name="resourcecoverage"> |
|
164 |
<xsl:with-param name="resfirstColStyle" select="$resfirstColStyle"/> |
|
165 |
<xsl:with-param name="ressubHeaderStyle" select="$ressubHeaderStyle"/> |
|
166 |
</xsl:call-template> |
|
167 |
</xsl:for-each> |
|
168 |
--> |
|
169 |
|
|
170 | 46 |
</xsl:template> |
171 | 47 |
|
172 | 48 |
<!-- style the alternate identifier elements --> |
... | ... | |
176 | 52 |
<xsl:if test="normalize-space(.)!=''"> |
177 | 53 |
<tr> |
178 | 54 |
<td class="{$resfirstColStyle}">Alternate Identifier:</td> |
179 |
<td class="{$ressecondColStyle}"><xsl:value-of select="."/></td> |
|
55 |
<td class="{$ressecondColStyle}"> |
|
56 |
<xsl:call-template name="i18n"> |
|
57 |
<xsl:with-param name="i18nElement" select="."/> |
|
58 |
</xsl:call-template> |
|
59 |
</td> |
|
180 | 60 |
</tr> |
181 | 61 |
</xsl:if> |
182 | 62 |
</xsl:template> |
... | ... | |
189 | 69 |
<xsl:if test="normalize-space(.)!=''"> |
190 | 70 |
<tr> |
191 | 71 |
<td class="{$resfirstColStyle}">Short Name:</td> |
192 |
<td class="{$ressecondColStyle}"><xsl:value-of select="."/></td> |
|
72 |
<td class="{$ressecondColStyle}"> |
|
73 |
<xsl:call-template name="i18n"> |
|
74 |
<xsl:with-param name="i18nElement" select="."/> |
|
75 |
</xsl:call-template> |
|
76 |
</td> |
|
193 | 77 |
</tr> |
194 | 78 |
</xsl:if> |
195 | 79 |
</xsl:template> |
... | ... | |
203 | 87 |
<tr> |
204 | 88 |
<td class="{$resfirstColStyle}">Title:</td> |
205 | 89 |
<td class="{$ressecondColStyle}"> |
206 |
<em class="bold"><xsl:value-of select="."/></em> |
|
90 |
<em class="bold"> |
|
91 |
<xsl:call-template name="i18n"> |
|
92 |
<xsl:with-param name="i18nElement" select="."/> |
|
93 |
</xsl:call-template> |
|
94 |
</em> |
|
207 | 95 |
</td> |
208 | 96 |
</tr> |
209 | 97 |
</xsl:if> |
... | ... | |
250 | 138 |
<xsl:template name="resourcelanguage"> |
251 | 139 |
<xsl:param name="resfirstColStyle"/> |
252 | 140 |
<xsl:if test="normalize-space(.)!=''"> |
253 |
<tr><td class="{$resfirstColStyle}"> |
|
254 |
Language:</td><td class="{$secondColStyle}"> |
|
255 |
<xsl:value-of select="."/></td></tr> |
|
141 |
<tr> |
|
142 |
<td class="{$resfirstColStyle}"> |
|
143 |
Language: |
|
144 |
</td> |
|
145 |
<td class="{$secondColStyle}"> |
|
146 |
<xsl:call-template name="i18n"> |
|
147 |
<xsl:with-param name="i18nElement" select="."/> |
|
148 |
</xsl:call-template> |
|
149 |
</td> |
|
150 |
</tr> |
|
256 | 151 |
</xsl:if> |
257 | 152 |
</xsl:template> |
258 | 153 |
|
... | ... | |
301 | 196 |
<xsl:if test="normalize-space(keyword)!=''"> |
302 | 197 |
<ul> |
303 | 198 |
<xsl:for-each select="keyword"> |
304 |
<li><xsl:value-of select="."/> |
|
305 |
<xsl:if test="./@keywordType and normalize-space(./@keywordType)!=''"> |
|
306 |
(<xsl:value-of select="./@keywordType"/>) |
|
307 |
</xsl:if> |
|
199 |
<li> |
|
200 |
<xsl:call-template name="i18n"> |
|
201 |
<xsl:with-param name="i18nElement" select="."/> |
|
202 |
</xsl:call-template> |
|
203 |
<xsl:if test="./@keywordType and normalize-space(./@keywordType)!=''"> |
|
204 |
(<xsl:value-of select="./@keywordType"/>) |
|
205 |
</xsl:if> |
|
308 | 206 |
</li> |
309 | 207 |
</xsl:for-each> |
310 | 208 |
</ul> |
... | ... | |
313 | 211 |
<xsl:if test="normalize-space(keyword)!=''"> |
314 | 212 |
<ul> |
315 | 213 |
<xsl:for-each select="keyword"> |
316 |
<li><xsl:value-of select="."/> |
|
214 |
<li> |
|
215 |
<xsl:call-template name="i18n"> |
|
216 |
<xsl:with-param name="i18nElement" select="."/> |
|
217 |
</xsl:call-template> |
|
317 | 218 |
<xsl:if test="./@keywordType and normalize-space(./@keywordType)!=''"> |
318 | 219 |
(<xsl:value-of select="./@keywordType"/>) |
319 | 220 |
</xsl:if> |
... | ... | |
371 | 272 |
</xsl:call-template> |
372 | 273 |
</td></tr> |
373 | 274 |
</xsl:template> |
275 |
|
|
276 |
<!-- for displaying any nested translation element for i18nNonEmptyString type --> |
|
277 |
<xsl:template name="i18n"> |
|
278 |
<xsl:param name="i18nElement"/> |
|
279 |
<!-- the primary value --> |
|
280 |
<xsl:if test="$i18nElement/text() != ''"> |
|
281 |
<xsl:if test="./@xml:lang != ''"> |
|
282 |
(<xsl:value-of select="./@xml:lang"/>) |
|
283 |
</xsl:if> |
|
284 |
<xsl:value-of select="$i18nElement/text()"/> |
|
285 |
</xsl:if> |
|
286 |
<!-- any translations --> |
|
287 |
<xsl:if test="count($i18nElement/value) > 0"> |
|
288 |
<br/> |
|
289 |
<xsl:for-each select="$i18nElement/value"> |
|
290 |
<xsl:if test="./@xml:lang != ''"> |
|
291 |
(<xsl:value-of select="./@xml:lang"/>) |
|
292 |
</xsl:if> |
|
293 |
<xsl:value-of select="."/> |
|
294 |
<xsl:if test="position() != last()"> |
|
295 |
<br/> |
|
296 |
</xsl:if> |
|
297 |
</xsl:for-each> |
|
298 |
</xsl:if> |
|
299 |
</xsl:template> |
|
374 | 300 |
|
375 | 301 |
|
376 | 302 |
</xsl:stylesheet> |
Also available in: Unified diff
handle i18n translation elements that are included in eml 2.1.1