Lines 2-8
Link Here
|
2 |
|
2 |
|
3 |
<!DOCTYPE stylesheet [<!ENTITY nbsp " " >]> |
3 |
<!DOCTYPE stylesheet [<!ENTITY nbsp " " >]> |
4 |
|
4 |
|
5 |
<xsl:stylesheet version="1.0" xmlns:marc="http://www.loc.gov/MARC21/slim" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> |
5 |
<xsl:stylesheet version="1.0" |
|
|
6 |
xmlns:marc="http://www.loc.gov/MARC21/slim" |
7 |
xmlns:xsl="http://www.w3.org/1999/XSL/Transform" |
8 |
exclude-result-prefixes="marc items"> |
6 |
|
9 |
|
7 |
<xsl:template name="datafield"> |
10 |
<xsl:template name="datafield"> |
8 |
<xsl:param name="tag"/> |
11 |
<xsl:param name="tag"/> |
Lines 23-59
Link Here
|
23 |
</xsl:element> |
26 |
</xsl:element> |
24 |
</xsl:template> |
27 |
</xsl:template> |
25 |
|
28 |
|
|
|
29 |
<xsl:template name="subfieldSelect"> |
30 |
<xsl:param name="codes"/> |
31 |
<xsl:param name="delimeter"><xsl:text> </xsl:text></xsl:param> |
32 |
<xsl:param name="subdivCodes"/> |
33 |
<xsl:param name="subdivDelimiter"/> |
34 |
<xsl:variable name="str"> |
35 |
<xsl:for-each select="marc:subfield"> |
36 |
<xsl:if test="contains($codes, @code)"> |
37 |
<xsl:if test="contains($subdivCodes, @code)"> |
38 |
<xsl:value-of select="$subdivDelimiter"/> |
39 |
</xsl:if> |
40 |
<xsl:value-of select="text()"/><xsl:value-of select="$delimeter"/> |
41 |
</xsl:if> |
42 |
</xsl:for-each> |
43 |
</xsl:variable> |
44 |
<xsl:value-of select="substring($str,1,string-length($str)-string-length($delimeter))"/> |
45 |
</xsl:template> |
46 |
|
47 |
<xsl:template name="buildSpaces"> |
48 |
<xsl:param name="spaces"/> |
49 |
<xsl:param name="char"><xsl:text> </xsl:text></xsl:param> |
50 |
<xsl:if test="$spaces>0"> |
51 |
<xsl:value-of select="$char"/> |
52 |
<xsl:call-template name="buildSpaces"> |
53 |
<xsl:with-param name="spaces" select="$spaces - 1"/> |
54 |
<xsl:with-param name="char" select="$char"/> |
55 |
</xsl:call-template> |
56 |
</xsl:if> |
57 |
</xsl:template> |
58 |
|
59 |
<xsl:template name="chopPunctuation"> |
60 |
<xsl:param name="chopString"/> |
61 |
<xsl:variable name="length" select="string-length($chopString)"/> |
62 |
<xsl:choose> |
63 |
<xsl:when test="$length=0"/> |
64 |
<xsl:when test="contains('.:,;/ ', substring($chopString,$length,1))"> |
65 |
<xsl:call-template name="chopPunctuation"> |
66 |
<xsl:with-param name="chopString" select="substring($chopString,1,$length - 1)"/> |
67 |
</xsl:call-template> |
68 |
</xsl:when> |
69 |
<xsl:when test="not($chopString)"/> |
70 |
<xsl:otherwise><xsl:value-of select="$chopString"/></xsl:otherwise> |
71 |
</xsl:choose> |
72 |
<xsl:text> </xsl:text> |
73 |
</xsl:template> |
74 |
|
75 |
<xsl:template name="addClassRtl"> |
76 |
<xsl:variable name="lang" select="marc:subfield[@code='7']" /> |
77 |
<xsl:if test="$lang = 'ha' or $lang = 'Hebrew' or $lang = 'fa' or $lang = 'Arabe'"> |
78 |
<xsl:attribute name="class">rtl</xsl:attribute> |
79 |
</xsl:if> |
80 |
</xsl:template> |
81 |
|
82 |
<xsl:template name="tag_title"> |
83 |
<xsl:param name="tag" /> |
84 |
<xsl:param name="label" /> |
85 |
<xsl:if test="marc:datafield[@tag=$tag]"> |
86 |
<span class="results_summary"> |
87 |
<span class="label"> |
88 |
<xsl:value-of select="$label"/>: </span> |
89 |
<xsl:for-each select="marc:datafield[@tag=$tag]"> |
90 |
<xsl:call-template name="addClassRtl" /> |
91 |
<xsl:for-each select="marc:subfield"> |
92 |
<xsl:choose> |
93 |
<xsl:when test="@code='a'"> |
94 |
<xsl:variable name="title" select="."/> |
95 |
<xsl:variable name="ntitle" |
96 |
select="translate($title, 'ˆ‰˜œ','')"/> |
97 |
<xsl:value-of select="$ntitle" /> |
98 |
</xsl:when> |
99 |
<xsl:when test="@code='b'"> |
100 |
<xsl:text>[</xsl:text> |
101 |
<xsl:value-of select="."/> |
102 |
<xsl:text>]</xsl:text> |
103 |
</xsl:when> |
104 |
<xsl:when test="@code='d'"> |
105 |
<xsl:text> = </xsl:text> |
106 |
<xsl:value-of select="."/> |
107 |
</xsl:when> |
108 |
<xsl:when test="@code='e'"> |
109 |
<xsl:text> : </xsl:text> |
110 |
<xsl:value-of select="."/> |
111 |
</xsl:when> |
112 |
<xsl:when test="@code='f'"> |
113 |
<xsl:text> / </xsl:text> |
114 |
<xsl:value-of select="."/> |
115 |
</xsl:when> |
116 |
<xsl:when test="@code='g'"> |
117 |
<xsl:text> ; </xsl:text> |
118 |
<xsl:value-of select="."/> |
119 |
</xsl:when> |
120 |
<xsl:otherwise> |
121 |
<xsl:if test="position()>1"> |
122 |
<xsl:text>, </xsl:text> |
123 |
</xsl:if> |
124 |
<xsl:value-of select="."/> |
125 |
</xsl:otherwise> |
126 |
</xsl:choose> |
127 |
</xsl:for-each> |
128 |
<xsl:if test="not (position() = last())"> |
129 |
<xsl:text> • </xsl:text> |
130 |
</xsl:if> |
131 |
</xsl:for-each> |
132 |
</span> |
133 |
</xsl:if> |
134 |
</xsl:template> |
135 |
|
136 |
<xsl:template name="tag_comma"> |
137 |
<xsl:param name="tag" /> |
138 |
<xsl:param name="label" /> |
139 |
<xsl:if test="marc:datafield[@tag=$tag]"> |
140 |
<span class="results_summary"> |
141 |
<span class="label"> |
142 |
<xsl:value-of select="$label"/>: </span> |
143 |
<xsl:for-each select="marc:datafield[@tag=$tag]"> |
144 |
<xsl:call-template name="addClassRtl" /> |
145 |
<xsl:for-each select="marc:subfield"> |
146 |
<xsl:if test="position()>1"> |
147 |
<xsl:text>, </xsl:text> |
148 |
</xsl:if> |
149 |
<xsl:value-of select="."/> |
150 |
</xsl:for-each> |
151 |
<xsl:if test="not (position() = last())"> |
152 |
<xsl:text> • </xsl:text> |
153 |
</xsl:if> |
154 |
</xsl:for-each> |
155 |
</span> |
156 |
</xsl:if> |
157 |
</xsl:template> |
158 |
|
26 |
<xsl:template name="tag_210"> |
159 |
<xsl:template name="tag_210"> |
27 |
<span class="results_summary"> |
160 |
<span class="results_summary"> |
28 |
<span class="label">Publication: </span> |
161 |
<span class="label">Publication:</span> |
29 |
<xsl:for-each select="marc:datafield[@tag=210]"> |
162 |
<xsl:for-each select="marc:datafield[@tag=210]"> |
30 |
<span> |
163 |
<span> |
31 |
<xsl:call-template name="addClassRtl" /> |
164 |
<xsl:call-template name="addClassRtl" /> |
32 |
<xsl:value-of select="marc:subfield[@code='a']"/> |
165 |
<xsl:for-each select="marc:subfield"> |
33 |
<xsl:if test="marc:subfield[@code='b']"> |
166 |
<xsl:choose> |
34 |
<xsl:if test="marc:subfield[@code='a']">, </xsl:if> |
167 |
<xsl:when test="@code='c' or @code='g'"> |
35 |
<xsl:value-of select="marc:subfield[@code='b']"/> |
168 |
<xsl:if test="position()>1"> |
36 |
</xsl:if> |
169 |
<xsl:text> : </xsl:text> |
37 |
<xsl:if test="marc:subfield[@code='a' or @code='b']"> |
170 |
</xsl:if> |
38 |
<xsl:if test="marc:subfield[@code='a']"> : </xsl:if> |
171 |
<xsl:value-of select="."/> |
39 |
<xsl:value-of select="marc:subfield[@code='c']"/> |
172 |
</xsl:when> |
40 |
</xsl:if> |
173 |
<xsl:otherwise> |
41 |
<xsl:if test="marc:subfield[@code='d']"> |
174 |
<xsl:if test="position()>1"> |
42 |
<xsl:if test="marc:subfield[@code='a' or @code='c']">, </xsl:if> |
175 |
<xsl:text>, </xsl:text> |
43 |
<xsl:value-of select="marc:subfield[@code='d']"/> |
176 |
</xsl:if> |
44 |
</xsl:if> |
177 |
<xsl:value-of select="."/> |
45 |
<xsl:if test="marc:subfield[@code='e']"> |
178 |
</xsl:otherwise> |
46 |
<xsl:if test="marc:subfield[@code='a' or @code='c' or @code='d']"> — </xsl:if> |
179 |
</xsl:choose> |
47 |
<xsl:value-of select="marc:subfield[@code='e']"/> |
180 |
</xsl:for-each> |
48 |
</xsl:if> |
|
|
49 |
<xsl:if test="marc:subfield[@code='g']"> |
50 |
<xsl:if test="marc:subfield[@code='e']"> : </xsl:if> |
51 |
<xsl:value-of select="marc:subfield[@code='g']"/> |
52 |
</xsl:if> |
53 |
<xsl:if test="marc:subfield[@code='h']"> |
54 |
<xsl:if test="marc:subfield[@code='e' or @code='g']">, </xsl:if> |
55 |
<xsl:value-of select="marc:subfield[@code='h']"/> |
56 |
</xsl:if> |
57 |
<xsl:if test="not (position() = last())"> |
181 |
<xsl:if test="not (position() = last())"> |
58 |
<xsl:text> • </xsl:text> |
182 |
<xsl:text> • </xsl:text> |
59 |
</xsl:if> |
183 |
</xsl:if> |
Lines 62-68
Link Here
|
62 |
</span> |
186 |
</span> |
63 |
</xsl:template> |
187 |
</xsl:template> |
64 |
|
188 |
|
65 |
<xsl:template name="tag_215"> |
189 |
<xsl:template name="tag_215"> |
66 |
<xsl:for-each select="marc:datafield[@tag=215]"> |
190 |
<xsl:for-each select="marc:datafield[@tag=215]"> |
67 |
<span class="results_summary"> |
191 |
<span class="results_summary"> |
68 |
<span class="label">Description: </span> |
192 |
<span class="label">Description: </span> |
Lines 82-300
Link Here
|
82 |
</xsl:for-each> |
206 |
</xsl:for-each> |
83 |
</xsl:template> |
207 |
</xsl:template> |
84 |
|
208 |
|
85 |
<xsl:template name="tag_4xx"> |
209 |
<xsl:template name="tag_onesubject"> |
86 |
<xsl:for-each select="marc:datafield[@tag=464 or @tag=461]"> |
210 |
<xsl:choose> |
87 |
<span class="results_summary"> |
211 |
<xsl:when test="marc:subfield[@code=9]"> |
88 |
<span class="label">Linked with: </span> |
212 |
<xsl:for-each select="marc:subfield"> |
89 |
<span> |
213 |
<xsl:if test="@code='9'"> |
90 |
<xsl:call-template name="addClassRtl" /> |
214 |
<xsl:variable name="start" select="position()"/> |
91 |
<xsl:if test="marc:subfield[@code='t']"> |
215 |
<xsl:variable name="ends"> |
92 |
<xsl:value-of select="marc:subfield[@code='t']"/> |
216 |
<xsl:for-each select="../marc:subfield[position() > $start]"> |
93 |
</xsl:if> |
217 |
<xsl:if test="@code=3 or @code=9 or @code=2"> |
94 |
<xsl:if test="marc:subfield[@code='e']"> : |
218 |
<xsl:variable name="end" select="position() + $start"/> |
95 |
<xsl:value-of select="marc:subfield[@code='e']"/> |
219 |
<xsl:value-of select="$end"/> |
96 |
</xsl:if> |
220 |
<xsl:text>,</xsl:text> |
97 |
<xsl:if test="marc:subfield[@code='f']"> / |
221 |
</xsl:if> |
98 |
<xsl:value-of select="marc:subfield[@code='f']"/> |
222 |
</xsl:for-each> |
99 |
</xsl:if> |
223 |
</xsl:variable> |
100 |
<xsl:if test="marc:subfield[@code='v']">, |
224 |
<xsl:variable name="end"> |
101 |
<xsl:value-of select="marc:subfield[@code='v']"/> |
225 |
<xsl:choose> |
102 |
</xsl:if> |
226 |
<xsl:when test="string-length($ends) > 0"> |
103 |
</span> |
227 |
<xsl:value-of select="substring-before($ends,',')"/> |
104 |
</span> |
228 |
</xsl:when> |
105 |
</xsl:for-each> |
229 |
<xsl:otherwise> |
106 |
</xsl:template> |
230 |
<xsl:text>1000</xsl:text> |
107 |
|
231 |
</xsl:otherwise> |
108 |
<xsl:template name="subfieldSelect"> |
232 |
</xsl:choose> |
109 |
<xsl:param name="codes"/> |
233 |
</xsl:variable> |
110 |
<xsl:param name="delimeter"><xsl:text> </xsl:text></xsl:param> |
234 |
<xsl:variable name="display"> |
111 |
<xsl:param name="subdivCodes"/> |
235 |
<xsl:for-each select="../marc:subfield[position() > $start and position() < $end]"> |
112 |
<xsl:param name="subdivDelimiter"/> |
236 |
<xsl:value-of select="."/> |
113 |
<xsl:variable name="str"> |
237 |
<xsl:if test="not(position()=last())"> |
114 |
<xsl:for-each select="marc:subfield"> |
238 |
<xsl:text>, </xsl:text> |
115 |
<xsl:if test="contains($codes, @code)"> |
239 |
</xsl:if> |
116 |
<xsl:if test="contains($subdivCodes, @code)"> |
240 |
</xsl:for-each> |
117 |
<xsl:value-of select="$subdivDelimiter"/> |
241 |
</xsl:variable> |
118 |
</xsl:if> |
242 |
<a> |
119 |
<xsl:value-of select="text()"/><xsl:value-of select="$delimeter"/> |
243 |
<xsl:attribute name="href"> |
120 |
</xsl:if> |
244 |
<xsl:text>/cgi-bin/koha/opac-search.pl?q=an:</xsl:text> |
121 |
</xsl:for-each> |
245 |
<xsl:value-of select="."/> |
122 |
</xsl:variable> |
246 |
</xsl:attribute> |
123 |
<xsl:value-of select="substring($str,1,string-length($str)-string-length($delimeter))"/> |
247 |
<xsl:value-of select="$display"/> |
124 |
</xsl:template> |
248 |
</a> |
125 |
|
249 |
<xsl:variable name="ncommas" |
126 |
<xsl:template name="buildSpaces"> |
250 |
select="string-length($ends) - string-length(translate($ends, ',', ''))" /> |
127 |
<xsl:param name="spaces"/> |
251 |
<xsl:if test="$ncommas > 1"> |
128 |
<xsl:param name="char"><xsl:text> </xsl:text></xsl:param> |
252 |
<xsl:text> -- </xsl:text> |
129 |
<xsl:if test="$spaces>0"> |
253 |
</xsl:if> |
130 |
<xsl:value-of select="$char"/> |
|
|
131 |
<xsl:call-template name="buildSpaces"> |
132 |
<xsl:with-param name="spaces" select="$spaces - 1"/> |
133 |
<xsl:with-param name="char" select="$char"/> |
134 |
</xsl:call-template> |
135 |
</xsl:if> |
136 |
</xsl:template> |
137 |
|
138 |
<xsl:template name="chopPunctuation"> |
139 |
<xsl:param name="chopString"/> |
140 |
<xsl:variable name="length" select="string-length($chopString)"/> |
141 |
<xsl:choose> |
142 |
<xsl:when test="$length=0"/> |
143 |
<xsl:when test="contains('.:,;/ ', substring($chopString,$length,1))"> |
144 |
<xsl:call-template name="chopPunctuation"> |
145 |
<xsl:with-param name="chopString" select="substring($chopString,1,$length - 1)"/> |
146 |
</xsl:call-template> |
147 |
</xsl:when> |
148 |
<xsl:when test="not($chopString)"/> |
149 |
<xsl:otherwise><xsl:value-of select="$chopString"/></xsl:otherwise> |
150 |
</xsl:choose> |
151 |
<xsl:text> </xsl:text> |
152 |
</xsl:template> |
153 |
|
154 |
<xsl:template name="addClassRtl"> |
155 |
<xsl:variable name="lang" select="marc:subfield[@code='7']" /> |
156 |
<xsl:if test="$lang = 'ha' or $lang = 'Hebrew' or $lang = 'fa' or $lang = 'Arabe'"> |
157 |
<xsl:attribute name="class">rtl</xsl:attribute> |
158 |
</xsl:if> |
159 |
</xsl:template> |
160 |
|
161 |
<xsl:template name="tag_title"> |
162 |
<xsl:param name="tag" /> |
163 |
<xsl:param name="label" /> |
164 |
<xsl:if test="marc:datafield[@tag=$tag]"> |
165 |
<span class="results_summary"> |
166 |
<span class="label"><xsl:value-of select="$label"/>: </span> |
167 |
<xsl:for-each select="marc:datafield[@tag=$tag]"> |
168 |
<xsl:value-of select="marc:subfield[@code='a']" /> |
169 |
<xsl:if test="marc:subfield[@code='d']"> |
170 |
<xsl:text> : </xsl:text> |
171 |
<xsl:value-of select="marc:subfield[@code='e']"/> |
172 |
</xsl:if> |
173 |
<xsl:if test="marc:subfield[@code='e']"> |
174 |
<xsl:for-each select="marc:subfield[@code='e']"> |
175 |
<xsl:text> </xsl:text> |
176 |
<xsl:value-of select="."/> |
177 |
</xsl:for-each> |
178 |
</xsl:if> |
179 |
<xsl:if test="marc:subfield[@code='f']"> |
180 |
<xsl:text> / </xsl:text> |
181 |
<xsl:value-of select="marc:subfield[@code='f']"/> |
182 |
</xsl:if> |
183 |
<xsl:if test="marc:subfield[@code='h']"> |
184 |
<xsl:text>, </xsl:text> |
185 |
<xsl:value-of select="marc:subfield[@code='h']"/> |
186 |
</xsl:if> |
187 |
<xsl:if test="marc:subfield[@code='i']"> |
188 |
<xsl:text>, </xsl:text> |
189 |
<xsl:value-of select="marc:subfield[@code='i']"/> |
190 |
</xsl:if> |
191 |
<xsl:if test="marc:subfield[@code='v']"> |
192 |
<xsl:text>, </xsl:text> |
193 |
<xsl:value-of select="marc:subfield[@code='v']"/> |
194 |
</xsl:if> |
195 |
<xsl:if test="marc:subfield[@code='x']"> |
196 |
<xsl:text>, </xsl:text> |
197 |
<xsl:value-of select="marc:subfield[@code='x']"/> |
198 |
</xsl:if> |
199 |
<xsl:if test="marc:subfield[@code='z']"> |
200 |
<xsl:text>, </xsl:text> |
201 |
<xsl:value-of select="marc:subfield[@code='z']"/> |
202 |
</xsl:if> |
254 |
</xsl:if> |
203 |
</xsl:for-each> |
255 |
</xsl:for-each> |
204 |
</span> |
256 |
</xsl:when> |
|
|
257 |
<xsl:otherwise> |
258 |
<a> |
259 |
<xsl:attribute name="href"> |
260 |
<xsl:text>/cgi-bin/koha/opac-search.pl?q=su:</xsl:text> |
261 |
<xsl:value-of select="marc:subfield[@code='a']"/> |
262 |
</xsl:attribute> |
263 |
<xsl:call-template name="chopPunctuation"> |
264 |
<xsl:with-param name="chopString"> |
265 |
<xsl:call-template name="subfieldSelect"> |
266 |
<xsl:with-param name="codes">abcdfijkmnpvxyz</xsl:with-param> |
267 |
<xsl:with-param name="subdivCodes">ijknpxyz</xsl:with-param> |
268 |
<xsl:with-param name="subdivDelimiter">-- </xsl:with-param> |
269 |
</xsl:call-template> |
270 |
</xsl:with-param> |
271 |
</xsl:call-template> |
272 |
</a> |
273 |
</xsl:otherwise> |
274 |
</xsl:choose> |
275 |
<xsl:if test="not(position()=last())"> |
276 |
<xsl:text> | </xsl:text> |
205 |
</xsl:if> |
277 |
</xsl:if> |
206 |
</xsl:template> |
278 |
</xsl:template> |
207 |
|
279 |
|
208 |
|
|
|
209 |
<xsl:template name="tag_subject"> |
280 |
<xsl:template name="tag_subject"> |
210 |
<xsl:param name="tag" /> |
281 |
<xsl:param name="tag" /> |
211 |
<xsl:param name="label" /> |
282 |
<xsl:param name="label" /> |
212 |
<xsl:if test="marc:datafield[@tag=$tag]"> |
283 |
<xsl:if test="marc:datafield[@tag=$tag]"> |
213 |
<span class="results_summary"> |
284 |
<span class="results_summary"> |
214 |
<span class="label"><xsl:value-of select="$label"/>: </span> |
285 |
<span class="label"> |
215 |
<xsl:for-each select="marc:datafield[@tag=$tag]"> |
286 |
<xsl:value-of select="$label"/> |
216 |
<a> |
287 |
<xsl:text>: </xsl:text> |
217 |
<xsl:choose> |
288 |
</span> |
218 |
<xsl:when test="marc:subfield[@code=9]"> |
289 |
<span class="value"> |
219 |
<xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute> |
290 |
<xsl:for-each select="marc:datafield[@tag=$tag]"> |
220 |
</xsl:when> |
291 |
<xsl:call-template name="tag_onesubject"> |
221 |
<xsl:otherwise> |
|
|
222 |
<xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=su:<xsl:value-of select="marc:subfield[@code='a']"/></xsl:attribute> |
223 |
</xsl:otherwise> |
224 |
</xsl:choose> |
225 |
<xsl:call-template name="chopPunctuation"> |
226 |
<xsl:with-param name="chopString"> |
227 |
<xsl:call-template name="subfieldSelect"> |
228 |
<xsl:with-param name="codes">abcdjpvxyz</xsl:with-param> |
229 |
<xsl:with-param name="subdivCodes">jpxyz</xsl:with-param> |
230 |
<xsl:with-param name="subdivDelimiter">-- </xsl:with-param> |
231 |
</xsl:call-template> |
232 |
</xsl:with-param> |
233 |
</xsl:call-template> |
292 |
</xsl:call-template> |
234 |
</a> |
293 |
</xsl:for-each> |
235 |
<xsl:if test="not (position()=last())"> |
294 |
</span> |
236 |
<xsl:text> | </xsl:text> |
|
|
237 |
</xsl:if> |
238 |
</xsl:for-each> |
239 |
</span> |
295 |
</span> |
240 |
</xsl:if> |
296 |
</xsl:if> |
241 |
</xsl:template> |
297 |
</xsl:template> |
242 |
|
298 |
|
243 |
|
|
|
244 |
<xsl:template name="tag_7xx"> |
299 |
<xsl:template name="tag_7xx"> |
245 |
<xsl:param name="tag" /> |
300 |
<xsl:param name="tag" /> |
246 |
<xsl:param name="label" /> |
301 |
<xsl:param name="label" /> |
247 |
<xsl:if test="marc:datafield[@tag=$tag]"> |
302 |
<xsl:if test="marc:datafield[@tag=$tag]"> |
248 |
<span class="results_summary"> |
303 |
<span class="results_summary"> |
249 |
<span class="label"><xsl:value-of select="$label" />: </span> |
304 |
<span class="label"> |
250 |
<xsl:for-each select="marc:datafield[@tag=$tag]"> |
305 |
<xsl:value-of select="$label" /> |
251 |
<span> |
306 |
<xsl:text>: </xsl:text> |
252 |
<xsl:call-template name="addClassRtl" /> |
307 |
</span> |
|
|
308 |
<span class="value"> |
309 |
<xsl:for-each select="marc:datafield[@tag=$tag]"> |
253 |
<a> |
310 |
<a> |
254 |
<xsl:choose> |
311 |
<xsl:choose> |
255 |
<xsl:when test="marc:subfield[@code=9]"> |
312 |
<xsl:when test="marc:subfield[@code=9]"> |
256 |
<xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute> |
313 |
<xsl:attribute name="href"> |
|
|
314 |
<xsl:text>/cgi-bin/koha/opac-search.pl?q=an:</xsl:text> |
315 |
<xsl:value-of select="marc:subfield[@code=9]"/> |
316 |
</xsl:attribute> |
257 |
</xsl:when> |
317 |
</xsl:when> |
258 |
<xsl:otherwise> |
318 |
<xsl:otherwise> |
259 |
<xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=au:<xsl:value-of select="marc:subfield[@code='a']"/><xsl:text> </xsl:text><xsl:value-of select="marc:subfield[@code='b']"/></xsl:attribute> |
319 |
<xsl:attribute name="href"> |
|
|
320 |
<xsl:text>/cgi-bin/koha/opac-search.pl?q=au:</xsl:text> |
321 |
<xsl:value-of select="marc:subfield[@code='a']"/> |
322 |
<xsl:text> </xsl:text> |
323 |
<xsl:value-of select="marc:subfield[@code='b']"/> |
324 |
</xsl:attribute> |
260 |
</xsl:otherwise> |
325 |
</xsl:otherwise> |
261 |
</xsl:choose> |
326 |
</xsl:choose> |
262 |
<xsl:if test="marc:subfield[@code='a']"> |
327 |
<xsl:for-each select="marc:subfield[@code='a' or @code='b' or @code='4' or @code='c' or @code='d' or @code='f' or @code='g' or @code='p']"> |
263 |
<xsl:value-of select="marc:subfield[@code='a']"/> |
328 |
<xsl:choose> |
264 |
</xsl:if> |
329 |
<xsl:when test="@code='9'"> |
265 |
<xsl:if test="marc:subfield[@code='b']"> |
330 |
</xsl:when> |
266 |
<xsl:text>, </xsl:text> |
331 |
<xsl:otherwise> |
267 |
<xsl:value-of select="marc:subfield[@code='b']"/> |
332 |
<xsl:value-of select="."/> |
268 |
</xsl:if> |
333 |
</xsl:otherwise> |
269 |
<xsl:if test="marc:subfield[@code='c']"> |
334 |
</xsl:choose> |
270 |
<xsl:text>, </xsl:text> |
335 |
<xsl:if test="not(position() = last())"> |
271 |
<xsl:value-of select="marc:subfield[@code='c']"/> |
336 |
<xsl:text>, </xsl:text> |
272 |
</xsl:if> |
337 |
</xsl:if> |
273 |
<xsl:if test="marc:subfield[@code='d']"> |
338 |
</xsl:for-each> |
274 |
<xsl:text> </xsl:text> |
|
|
275 |
<xsl:value-of select="marc:subfield[@code='d']"/> |
276 |
</xsl:if> |
277 |
<xsl:if test="marc:subfield[@code='f']"> |
278 |
<span dir="ltr"> |
279 |
<xsl:text> (</xsl:text> |
280 |
<xsl:value-of select="marc:subfield[@code='f']"/> |
281 |
<xsl:text>)</xsl:text> |
282 |
</span> |
283 |
</xsl:if> |
284 |
<xsl:if test="marc:subfield[@code='g']"> |
285 |
<xsl:text> </xsl:text> |
286 |
<xsl:value-of select="marc:subfield[@code='g']"/> |
287 |
</xsl:if> |
288 |
<xsl:if test="marc:subfield[@code='p']"> |
289 |
<xsl:text> </xsl:text> |
290 |
<xsl:value-of select="marc:subfield[@code='p']"/> |
291 |
</xsl:if> |
292 |
</a> |
339 |
</a> |
293 |
</span> |
340 |
<xsl:if test="not(position() = last())"> |
294 |
<xsl:if test="not (position() = last())"> |
341 |
<span style="padding: 3px;"> |
295 |
<xsl:text> ; </xsl:text> |
342 |
<xsl:text>;</xsl:text> |
296 |
</xsl:if> |
343 |
</span> |
297 |
</xsl:for-each> |
344 |
</xsl:if> |
|
|
345 |
</xsl:for-each> |
346 |
</span> |
298 |
</span> |
347 |
</span> |
299 |
</xsl:if> |
348 |
</xsl:if> |
300 |
</xsl:template> |
349 |
</xsl:template> |
301 |
- |
|
|