Revision 3178
Added by sledge almost 18 years ago
entity.xsl | ||
---|---|---|
1 |
<?xml version="1.0"?> |
|
1 |
<?xml version="1.0" encoding="UTF-8"?>
|
|
2 | 2 |
<!-- |
3 | 3 |
* '$RCSfile$' |
4 | 4 |
* Authors: Matt Jones, CHad Berkley |
... | ... | |
28 | 28 |
* convert an XML file showing the resultset of a query |
29 | 29 |
* into an HTML format suitable for rendering with modern web browsers. |
30 | 30 |
--> |
31 |
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> |
|
31 |
<xsl:stylesheet |
|
32 |
xmlns:xsl="http://www.w3.org/1999/XSL/Transform" |
|
33 |
xmlns="http://www.w3.org/1999/xhtml" |
|
34 |
version="1.0"> |
|
32 | 35 |
|
33 |
<xsl:output method="html"/> |
|
36 |
<xsl:output method="xml" encoding="utf-8" |
|
37 |
doctype-public="-//W3C//DTD XHTML 1.1//EN" |
|
38 |
doctype-system="http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd" |
|
39 |
indent="yes" /> |
|
40 |
|
|
34 | 41 |
<xsl:param name="sessid"/> |
35 | 42 |
<xsl:param name="qformat">default</xsl:param> |
36 | 43 |
<xsl:param name="enableediting">false</xsl:param> |
44 |
|
|
37 | 45 |
<xsl:template match="/"> |
38 |
<html> |
|
39 |
<head><title>Details for <xsl:value-of select="/entity/@name"/> </title> |
|
40 |
<link rel="stylesheet" type="text/css" |
|
46 |
<html xml:lang="en-US"> |
|
47 |
<head> |
|
48 |
<title><xsl:value-of select="/entity/@name"/></title> |
|
49 |
<link rel="stylesheet" type="text/css" |
|
41 | 50 |
href="@style-skins-path@/{$qformat}/{$qformat}.css" /> |
51 |
|
|
52 |
<style type="text/css"> |
|
53 |
<xsl:text disable-output-escaping="yes"> |
|
54 |
body, a, p, td, tr, h3, h2, h1 |
|
55 |
{ |
|
56 |
font-family: Arial, Helvetica, sans-serif; |
|
57 |
} |
|
58 |
|
|
59 |
body |
|
60 |
{ |
|
61 |
background: #ece9d8; |
|
62 |
margin: 0; |
|
63 |
} |
|
64 |
|
|
65 |
tr.top-level > td |
|
66 |
{ |
|
67 |
text-align: left; |
|
68 |
} |
|
69 |
|
|
70 |
tr.top-level > td |
|
71 |
{ |
|
72 |
background: white; |
|
73 |
border: 0.125em ridge white; |
|
74 |
padding: 0.375em; |
|
75 |
} |
|
76 |
|
|
77 |
td tr |
|
78 |
{ |
|
79 |
vertical-align: top; |
|
80 |
} |
|
81 |
|
|
82 |
td td |
|
83 |
{ |
|
84 |
padding: 0.1875em; |
|
85 |
} |
|
86 |
</xsl:text> |
|
87 |
</style> |
|
42 | 88 |
</head> |
43 |
<body> |
|
44 |
<h2><xsl:value-of select="/entity/@name"/></h2> |
|
45 |
<p><xsl:value-of select="/entity/property[@name='documentation']/property[@name='description']/configure"/></p> |
|
46 |
Author: <b><xsl:value-of select="/entity/property[@name='documentation']/property[@name='author']/configure"/></b><br/> |
|
47 |
Version: <b><xsl:value-of select="/entity/property[@name='documentation']/property[@name='version']/configure"/></b><br/> |
|
48 |
Class: <b><xsl:value-of select="/entity/property[@name='class']/@value"/></b><br/> |
|
49 |
LSID: <b><xsl:value-of select="/entity/property[@name='entityId']/@value"/></b><br/> |
|
50 |
<a> |
|
51 |
<xsl:attribute name="href">http://@server@/authority/data?lsid=<xsl:value-of select="/entity/property[@name='karId']/@value"/></xsl:attribute> |
|
52 |
<xsl:text>Download</xsl:text> |
|
53 |
</a> |
|
54 |
</body> |
|
89 |
|
|
90 |
<body> |
|
91 |
<table cellspacing="8" cellpadding="0" style="border: none; width: 100%;" class="main"> |
|
92 |
<colgroup></colgroup> |
|
93 |
<colgroup style="width: 100%;"></colgroup> |
|
94 |
<colgroup></colgroup> |
|
95 |
|
|
96 |
<tr class="top-level"> |
|
97 |
<td colspan="2"> |
|
98 |
<h1> |
|
99 |
<span style="padding-right: 2em;"> |
|
100 |
<xsl:value-of select="/entity/@name"/> |
|
101 |
</span> |
|
102 |
|
|
103 |
<xsl:text> (</xsl:text> |
|
104 |
<xsl:value-of select="/entity/property[@name='class']/@value"/> |
|
105 |
<xsl:text>)</xsl:text> |
|
106 |
</h1> |
|
107 |
</td> |
|
108 |
|
|
109 |
<td style="white-space: nowrap; width: 1px;"> |
|
110 |
<table cellspacing="0" cellpadding="0"> |
|
111 |
<xsl:if test="count(/entity/property[@name='documentation']/property[@name='author']) > 0"> |
|
112 |
<tr> |
|
113 |
<td style="font-style: italic;"> |
|
114 |
Author: |
|
115 |
</td> |
|
116 |
|
|
117 |
<td> |
|
118 |
<xsl:for-each select="/entity/property[@name='documentation']/property[@name='author']"> |
|
119 |
<xsl:if test="position() > 0"> |
|
120 |
<xsl:text>, </xsl:text> |
|
121 |
</xsl:if> |
|
122 |
|
|
123 |
<xsl:value-of select="configure"/> |
|
124 |
</xsl:for-each> |
|
125 |
</td> |
|
126 |
</tr> |
|
127 |
</xsl:if> |
|
128 |
|
|
129 |
<xsl:if test="count(/entity/property[@name='documentation']/property[@name='version']) > 0"> |
|
130 |
<tr> |
|
131 |
<td style="font-style: italic;"> |
|
132 |
Version: |
|
133 |
</td> |
|
134 |
|
|
135 |
<td> |
|
136 |
<xsl:value-of select="/entity/property[@name='documentation']/property[@name='version']/configure"/> |
|
137 |
</td> |
|
138 |
</tr> |
|
139 |
</xsl:if> |
|
140 |
</table> |
|
141 |
</td> |
|
142 |
</tr> |
|
143 |
|
|
144 |
<tr class="top-level" style="vertical-align: top;"> |
|
145 |
<td> |
|
146 |
<img alt="Actor Image"> |
|
147 |
<xsl:attribute name="src"> |
|
148 |
<xsl:text>metacat?qformat=</xsl:text> |
|
149 |
<xsl:value-of select="$qformat"/> |
|
150 |
<xsl:text>&sessionid=</xsl:text> |
|
151 |
<xsl:value-of select="$sessid"/> |
|
152 |
<xsl:text>&action=read&docid=</xsl:text> |
|
153 |
<!--xsl:value-of select="./docid"/--><xsl:text>PLASMA</xsl:text> |
|
154 |
</xsl:attribute> |
|
155 |
</img> |
|
156 |
|
|
157 |
<div style="text-align: center;"> |
|
158 |
<a> |
|
159 |
<xsl:attribute name="href">http://@server@/authority/data?lsid=<xsl:value-of select="/entity/property[@name='karId']/@value"/></xsl:attribute> |
|
160 |
<xsl:text>Download</xsl:text> |
|
161 |
</a> |
|
162 |
</div> |
|
163 |
</td> |
|
164 |
|
|
165 |
<td colspan="2"> |
|
166 |
<xsl:value-of select="/entity/property[@name='documentation']/property[@name='description']/configure"/> |
|
167 |
|
|
168 |
<xsl:if test="count(/entity/property[@name='documentation']/property[@name='userLevelDocumentation']"> |
|
169 |
<p><xsl:value-of select="/entity/property[@name='documentation']/property[@name='userLevelDocumentation']/configure"/></p> |
|
170 |
</xsl:if> |
|
171 |
</td> |
|
172 |
</tr> |
|
173 |
|
|
174 |
<tr class="top-level"> |
|
175 |
<td colspan="3"> |
|
176 |
<table cellspacing="0" cellpadding="0"> |
|
177 |
<xsl:if test="count(/entity/property[@name='documentation']/property[substring(@name, 0, 5)='prop:']) > 0"> |
|
178 |
<tr> |
|
179 |
<td colspan="2"> |
|
180 |
<h2>Parameters</h2> |
|
181 |
</td> |
|
182 |
</tr> |
|
183 |
|
|
184 |
<xsl:for-each select="/entity/property[@name='documentation']/property[substring(@name, 0, 5)='prop:']"> |
|
185 |
<tr> |
|
186 |
<td style="font-style: italic;"> |
|
187 |
<xsl:value-of select="substring(@name, 5)"/> |
|
188 |
</td> |
|
189 |
|
|
190 |
<td> |
|
191 |
<xsl:value-of select="configure"/> |
|
192 |
</td> |
|
193 |
</tr> |
|
194 |
</xsl:for-each> |
|
195 |
</xsl:if> |
|
196 |
|
|
197 |
<xsl:if test="count(/entity/property[@name='documentation']/property[substring(@name, 0, 5)='port:']) > 0"> |
|
198 |
<tr> |
|
199 |
<td colspan="2"> |
|
200 |
<h2>Ports</h2> |
|
201 |
</td> |
|
202 |
</tr> |
|
203 |
|
|
204 |
<xsl:for-each select="/entity/property[@name='documentation']/property[substring(@name, 0, 5)='port:']"> |
|
205 |
<tr> |
|
206 |
<td style="font-style: italic;"> |
|
207 |
<xsl:value-of select="substring(@name, 5)"/> |
|
208 |
</td> |
|
209 |
|
|
210 |
<td> |
|
211 |
<xsl:value-of select="configure"/> |
|
212 |
</td> |
|
213 |
</tr> |
|
214 |
</xsl:for-each> |
|
215 |
</xsl:if> |
|
216 |
</table> |
|
217 |
</td> |
|
218 |
</tr> |
|
219 |
</table> |
|
220 |
</body> |
|
55 | 221 |
</html> |
56 |
</xsl:template> |
|
222 |
</xsl:template> |
|
223 |
</xsl:stylesheet> |
|
57 | 224 |
|
58 |
</xsl:stylesheet> |
Also available in: Unified diff
Kepler Repository Skin