root/greenstone3/trunk/web/interfaces/oran/transform/util.xsl @ 20192

Revision 20192, 22.1 KB (checked in by kjdon, 11 years ago)

added in a few namespace declarations that are needed now

Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<xsl:stylesheet version="1.0"
3    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
4    xmlns:xslt="http://www.w3.org/1999/XSL/Transform"
5    xmlns:gslib="http://www.greenstone.org/XSL/Library"
6        xmlns:gsf="http://www.greenstone.org/greenstone3/schema/ConfigFormat"
7    xmlns:util="http://org.greenstone.gsdl3.util.XSLTUtil"
8    exclude-result-prefixes="util gslib gsf xslt">
9
10    <!-- some global parameters - these are set by whoever is invoking the transformation -->
11  <xsl:param name="interface_name"/>
12  <xsl:param name="library_name"/>
13
14  <!-- every pages ....................................................................... -->
15    <xsl:template name="siteName"><xsl:value-of select="/page/pageResponse/metadataList/metadata[@name='siteName']"/></xsl:template>
16    <xsl:template name="siteLink"><a href="./"><xsl:call-template name="siteName"/></a></xsl:template>
17
18    <xsl:variable name="a"><xsl:value-of select="/page/pageRequest/paramList/param[@name='a']/@value"/>     </xsl:variable>
19    <xsl:variable name="collections" select="/page/pageResponse/collectionList/collection"/>
20
21    <xsl:variable name="berrybasketswitch"><xsl:value-of select="/page/pageRequest/paramList/param[@name='berrybasket']/@value"/></xsl:variable>
22    <xsl:variable name="berryBasketOn" select="/page/pageRequest/paramList/param[@name='berrybasket' and @value='on']"/>
23
24    <!-- template to get the name of the current collection -->
25    <xsl:template name="collectionName">
26        <xsl:choose>
27            <xsl:when test="/page/pageResponse/collection"><xsl:value-of select="/page/pageResponse/collection/displayItem[@name='name']"/></xsl:when>
28            <xsl:otherwise>All Collections</xsl:otherwise>
29        </xsl:choose>
30    </xsl:template>
31
32    <xsl:template name="collectionNameShort">
33        <xsl:value-of select="/page/pageResponse/collection/@name"/>
34    </xsl:template>
35
36    <xsl:template name="collectionNameLinked">
37        <xsl:choose>
38            <xsl:when test="/page/pageResponse/collection">
39                <a>
40                    <xsl:attribute name="href"><xsl:call-template name="siteURL"/><xsl:value-of select="$library_name"/>?a=p&amp;sa=about&amp;c=<xsl:call-template name="collectionNameShort"/></xsl:attribute>
41                    <xsl:call-template name="collectionName"/>
42                </a>
43            </xsl:when>
44            <xsl:otherwise>
45                <a>
46                    <xsl:attribute name="href"><xsl:call-template name="siteURL"/></xsl:attribute>
47                    All Collections
48                </a>
49            </xsl:otherwise>
50        </xsl:choose>
51    </xsl:template>
52
53    <!-- text to get the name of the current service ("Browse","Search" etc) -->
54    <xsl:template name="serviceName">
55        <xsl:value-of select="/page/pageResponse/service/displayItem[@name='name']"/>
56    </xsl:template>
57
58    <xsl:template name="textDirectionAttribute">
59        <xsl:attribute name="dir">
60            <xsl:choose>
61                <xsl:when test="/page/@lang='ar' or /page/@lang='fa' or /page/@lang='he' or /page/@lang='ur' or /page/@lang='ps' or /page/@lang='prs'">rtl</xsl:when>
62                <xsl:otherwise>ltr</xsl:otherwise>
63            </xsl:choose>
64        </xsl:attribute>
65    </xsl:template>
66
67    <xsl:template name="actionClass">
68        <xsl:attribute name="class"><xsl:value-of select="/page/pageRequest/@action"/>Action <xsl:if test="/page/pageRequest/@subaction"><xsl:value-of select="/page/pageRequest/@subaction"/>Subaction</xsl:if></xsl:attribute>
69    </xsl:template>
70
71    <!-- username, if logged in -->
72    <!--
73    <xsl:template name="username">
74        <xsl:if test="$un_s!=''">
75            <xsl:if test="$asn!='' and $asn!='0'">
76            <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'authen.username')"/>  :  <xsl:value-of select="$un_s"/>
77            </xsl:if>
78        </xsl:if>
79    </xsl:template>
80    -->
81
82    <xsl:template name="defaultDividerBar">
83   <xsl:param name='text'/>
84      <xsl:choose>
85      <xsl:when test="$text">
86     <div class="divbar"><xsl:value-of select="$text"/></div>
87      </xsl:when>
88      <xsl:otherwise>
89     <div class="divbar"><xsl:text disable-output-escaping="yes">&amp;nbsp;</xsl:text></div>
90      </xsl:otherwise>
91    </xsl:choose>
92  </xsl:template>
93
94
95    <xsl:template match="error">
96    Error: <xsl:value-of select="."/>
97  </xsl:template>
98
99
100<xsl:template name="displayErrorsIfAny">
101      <xsl:if test="descendant::error">
102      <script language="Javascript">
103    <xsl:text disable-output-escaping="yes">
104      function removeAllChildren(node) {
105        while (node.hasChildNodes()) {
106          node.removeChild(node.firstChild);
107        }
108      }
109
110      function toggleHideError(obj) {
111        if (obj.style.display == "none") {
112          obj.style.display = "";
113          hide_link = document.getElementById("hide");
114          removeAllChildren(hide_link);
115          hide_link.appendChild(document.createTextNode("</xsl:text><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'hide_error')"/><xsl:text disable-output-escaping="yes">"));
116        } else {
117          obj.style.display = "none";
118          hide_link = document.getElementById("hide");
119          removeAllChildren(hide_link);
120          hide_link.appendChild(document.createTextNode("</xsl:text><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'show_error')"/><xsl:text disable-output-escaping="yes">"));
121        }
122      }
123    </xsl:text>
124      </script>
125      <p align='right'><a id="hide" href="javascript:toggleHideError(error);"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'show_error')"/></a></p>
126      <div id="error" style="display: none;">
127    <xsl:apply-templates select="descendant::error"/>
128      </div>
129    </xsl:if>
130</xsl:template>
131
132
133    <xsl:template name="noTextBar">
134        <xsl:text disable-output-escaping="yes">&amp;nbsp;</xsl:text>
135    </xsl:template>
136   
137   
138    <xsl:template name="poweredByGS3TextBar">
139        <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'gs3power')"/>
140    </xsl:template>
141
142    <xsl:template name="rightArrow"><xsl:text disable-output-escaping="yes"> &amp;raquo; </xsl:text></xsl:template>
143
144
145
146    <!-- site home ....................................................................... -->
147
148<xsl:template name="siteHomePageTitle">
149 <!-- put a space in the title in case the actual value is missing - mozilla will not display a page with no title-->
150<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'gsdl')"/><xsl:text> </xsl:text>
151</xsl:template>
152
153
154    <xsl:template name="selectACollectionTextBar">
155     <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home.select_a_collection')"/>
156  </xsl:template>
157    <xsl:template name="crossCollectionQuickSearchForm">
158        <xsl:apply-templates select="serviceList/service[@name='TextQuery']"/>
159    </xsl:template>
160   
161    <xsl:template match="service[@name='TextQuery']">
162        <form name="QuickSearch" method="get" action="{$library_name}">
163            <input type="hidden" name="a" value="q"/>
164            <input type="hidden" name="rt" value="rd"/>
165            <input type="hidden" name="s" value="{@name}"/>
166            <input type="hidden" name="s1.collection" value="all"/>
167            <input type="text" name="s1.query" size="20"/>
168            <input type="submit"><xsl:attribute name="value"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home.quick_search')"/></xsl:attribute></input>
169        </form>
170    </xsl:template>
171
172    <xsl:template name="collectionLinkWithImage">
173        <xsl:choose>
174            <xsl:when test="displayItem[@name='icon']">
175                <!-- <a href="{$library_name}/{@name}"> -->
176                <a href="{$library_name}?a=p&amp;sa=about&amp;c={@name}">
177                    <xsl:attribute name="style">background-image: url('<xsl:value-of select="metadataList/metadata[@name='httpPath']"/>/images/icon-160x120.gif');</xsl:attribute>
178                    <b><xsl:value-of select="displayItem[@name='name']"/></b>
179                </a>
180            </xsl:when>
181            <xsl:otherwise>
182                <a href="{$library_name}?a=p&amp;sa=about&amp;c={@name}">
183                    <xsl:value-of select="displayItem[@name='name']"/>
184                </a>
185            </xsl:otherwise>
186        </xsl:choose>
187    </xsl:template>
188
189
190    <xsl:template name="serviceClusterList">
191        <xsl:apply-templates select="serviceClusterList"/>
192    </xsl:template>
193   
194      <xsl:template match="serviceClusterList">
195        <xsl:for-each select="serviceCluster">
196          <a href="{$library_name}?a=p&amp;sa=about&amp;c={@name}"><xsl:value-of select='@name'/><xsl:value-of select="displayItem[@name='name']"/></a>
197        </xsl:for-each>
198      </xsl:template>
199
200   
201    <xsl:template name="serviceLink">
202        <div class="paramLabel"><a href="{$library_name}?a=q&amp;rt=d&amp;s={@name}"><xsl:value-of select="displayItem[@name='name']"/></a></div>
203        <div class="paramValue"><xsl:value-of select="displayItem[@name='description']"/></div>
204        <br class="clear"/>
205    </xsl:template>
206
207
208   <xsl:template name="authenticationLink">
209   <xsl:for-each select="serviceList/service[@type='authen']">
210      <li><a href="{$library_name}?a=g&amp;rt=r&amp;sa=authen&amp;s={@name}&amp;s1.aup=Login&amp;s1.un=&amp;s1.asn="><xsl:value-of select="displayItem[@name='name']"/></a><xsl:value-of select="displayItem[@name='description']"/></li></xsl:for-each>
211  </xsl:template>
212   <xsl:template name="libraryInterfaceLink">
213   <li><a href="{$library_name}?a=p&amp;sa=gli4gs3"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home.librarian_interface')"/></a></li>
214  </xsl:template>
215<xsl:template name="greenstoneLogoAlternateText">
216<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'gsdl')"/>
217</xsl:template>
218
219<!-- about page - collection home ....................................................................... -->
220<xsl:variable name="collName" select="/page/pageRequest/paramList/param[@name='c']/@value"/>
221<xsl:param name="collName" select="/page/pageRequest/paramList/param[@name='c']/@value"/>
222<xsl:param name="pageType"/>
223<xsl:variable name="this-element" select="/page/pageResponse/collection|/page/pageResponse/serviceCluster"/>
224<xsl:variable name="this-service" select="/page/pageResponse/service/@name"/>
225
226
227<xsl:template name="aboutCollectionPageTitle">
228 <!-- put a space in the title in case the actual value is missing - mozilla will not display a page with no title-->
229<xsl:value-of select="/page/pageResponse/collection/displayItem[@name='name']"/><xsl:text> </xsl:text>
230</xsl:template>
231
232   
233<xsl:template name="collectionHomeLinkWithLogoIfAvailable">
234<a href="{$library_name}?a=p&amp;sa=about&amp;c={$collName}">
235      <xsl:choose>
236        <xsl:when test="$this-element/displayItem[@name='icon']">
237          <img border="0">
238        <xsl:attribute name="src">
239          <xsl:value-of select="$this-element/metadataList/metadata[@name='httpPath']"/>/images/<xsl:value-of select="$this-element/displayItem[@name='icon']"/>
240        </xsl:attribute>   
241        <xsl:attribute name="alt">
242          <xsl:value-of select="$this-element/displayItem[@name='name']"/>
243        </xsl:attribute>
244        <xsl:attribute name="title">
245          <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'aboutpage')"/>
246        </xsl:attribute>
247          </img>
248        </xsl:when>
249        <xsl:otherwise>
250          <xsl:value-of select="$this-element/displayItem[@name='name']"/>
251        </xsl:otherwise>
252      </xsl:choose>
253    </a>
254</xsl:template>
255
256
257<xsl:template name="homeButtonTop">
258<a href="{$library_name}?a=p&amp;sa=home"><xsl:attribute name="title"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home_tip')"/></xsl:attribute>
259<xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home_b')"/></a>
260</xsl:template>
261
262
263<xsl:template name="helpButtonTop">
264    <xsl:choose>
265      <xsl:when test="$pageType='help'">
266    <li><a><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_b')"/></a></li>
267      </xsl:when>
268      <xsl:otherwise>
269    <li><a href="{$library_name}?a=p&amp;sa=help&amp;c={$collName}"><xsl:attribute name="title"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_tip')"/></xsl:attribute>
270        <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_b')"/>
271      </a></li>
272      </xsl:otherwise>
273    </xsl:choose>
274</xsl:template>
275
276
277    <xsl:template name="preferencesButtonTop">
278        <xsl:choose>
279            <xsl:when test="$pageType='pref'">
280                <li><a><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_b')"/></a></li>
281            </xsl:when>
282            <xsl:otherwise>
283                <li><a href="{$library_name}?a=p&amp;sa=pref&amp;c={$collName}"><xsl:attribute name="title"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_tip')"/></xsl:attribute>
284                    <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_b')"/>
285                </a></li>
286            </xsl:otherwise>
287        </xsl:choose>
288    </xsl:template>
289
290    <xsl:template name="servicesNavigationBar">
291        <xsl:for-each select="$this-element/serviceList/service">
292            <xsl:variable name="action"><xsl:choose>
293                <xsl:when test="@name=$this-service">CURRENT</xsl:when>
294                <xsl:when test="@type='query'">q</xsl:when>
295                <xsl:when test="@type='browse'">b</xsl:when>
296                <xsl:when test="@type='process'">pr</xsl:when>
297                <xsl:when test="@type='applet'">a</xsl:when>
298                <xsl:otherwise>DO_NOT_DISPLAY</xsl:otherwise>
299            </xsl:choose></xsl:variable>
300            <xsl:choose>
301                <xsl:when test="$action='CURRENT'">
302                    <li><a><xsl:value-of select="displayItem[@name='name']"/></a></li>
303                </xsl:when>
304                <xsl:when test="$action !='DO_NOT_DISPLAY'">
305                    <li><a href="{$library_name}?a={$action}&amp;rt=d&amp;s={@name}&amp;c={$collName}"><xsl:if test="displayItem[@name='description']"><xsl:attribute name='title'><xsl:value-of select="displayItem[@name='description']"/></xsl:attribute></xsl:if><xsl:value-of select="displayItem[@name='name']"/></a></li>
306                </xsl:when>
307            </xsl:choose>
308        </xsl:for-each>
309    </xsl:template>
310
311
312    <xsl:template name="collectionDescriptionTextAndServicesLinks">
313        <xsl:apply-templates select="pageResponse/collection|serviceCluster"/>
314    </xsl:template>
315
316    <xsl:template match="collection|serviceCluster">
317        <xsl:value-of select="displayItem[@name='description']" disable-output-escaping="yes"/>
318        <xsl:apply-templates select="serviceList">
319            <xsl:with-param name="collName" select="$collName"/>
320        </xsl:apply-templates>
321    </xsl:template>
322
323
324    <xsl:template match="serviceList">
325        <xsl:param name="collName"/>
326        <h3><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'about.services')"/></h3>
327        <p>
328            <xsl:choose>
329                <xsl:when test="service">
330                    <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'about.servicehelp')"/>
331                </xsl:when>
332                <xsl:otherwise>
333                    <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'about.noservices')"/>
334                </xsl:otherwise>
335            </xsl:choose>
336        </p>
337
338        <xsl:if test="service">
339            <div id="servicelist">
340                <xsl:for-each select="service">
341                    <xsl:sort select="position()" order="descending" data-type="number"/>
342
343                    <xsl:variable name="action"><xsl:choose>
344                        <xsl:when test="@type='query'">q</xsl:when>
345                        <xsl:when test="@type='browse'">b</xsl:when>
346                        <xsl:when test="@type='process'">pr</xsl:when>
347                        <xsl:when test="@type='applet'">a</xsl:when>
348                        <xsl:otherwise>DO_NOT_DISPLAY</xsl:otherwise>
349                    </xsl:choose></xsl:variable>
350                    <xsl:if test="$action != 'DO_NOT_DISPLAY'">
351                        <div class="paramLabel"><a href="{$library_name}?a={$action}&amp;rt=d&amp;s={@name}&amp;c={$collName}"><xsl:value-of select="displayItem[@name='name']"/></a></div>
352                        <div class="paramLabel"><xsl:value-of select="displayItem[@name='description']"/></div>
353                        <br class="clear"/>
354                    </xsl:if>
355                </xsl:for-each>
356            </div>
357        </xsl:if>
358    </xsl:template>
359
360
361
362<!-- classifier page ............................................................................ -->
363
364
365<xsl:template name="navigationTab">
366
367    <xsl:variable name="isCurrent" select="@name=/page/pageResponse/service/@name"/>
368
369    <xsl:variable name="action"><xsl:choose>
370        <xsl:when test="@type='query'">q</xsl:when>
371        <xsl:when test="@type='browse'">b</xsl:when>
372        <xsl:when test="@type='process'">pr</xsl:when>
373        <xsl:when test="@type='applet'">a</xsl:when>
374        <xsl:otherwise>DO_NOT_DISPLAY</xsl:otherwise>
375    </xsl:choose></xsl:variable>
376
377    <xsl:if test="$action!='DO_NOT_DISPLAY'">
378        <li>
379            <xsl:if test="$isCurrent">
380                <xsl:attribute name="class">current</xsl:attribute>
381            </xsl:if>
382            <a>
383                <xsl:if test="displayItem[@name='description']">
384                    <xsl:attribute name='title'><xsl:value-of select="displayItem[@name='description']"/></xsl:attribute>
385                </xsl:if>
386                <xsl:attribute name="href"><xsl:value-of select="$library_name"/>?a=<xsl:value-of select="$action"/>&amp;rt=d&amp;s=<xsl:value-of select="@name"/>&amp;c=<xsl:value-of select="/page/pageResponse/collection/@name"/></xsl:attribute>
387                <xsl:value-of select="displayItem[@name='name']"/>
388            </a>
389        </li>
390    </xsl:if>
391
392</xsl:template>
393
394
395<xsl:template name="classifierLink">
396    <xsl:if test="@name=/page/pageResponse/classifier/@name"><xsl:attribute name="class">current</xsl:attribute></xsl:if>
397    <a href="{$library_name}?a=b&amp;rt=r&amp;s={/page/pageResponse/service/@name}&amp;c={/page/pageResponse/collection/@name}&amp;cl={@name}">
398        <xsl:value-of select="displayItem[@name='description']"/>
399    </a>
400</xsl:template>
401
402<!-- query page ............................................................................ -->
403
404    <xsl:template name="indexName">
405        <xsl:value-of select="/page/pageResponse/service/displayItem[@name='name']"/>
406    </xsl:template>
407
408<xsl:template name="queryPageCollectionName">
409    <xsl:choose><xsl:when test="/page/pageResponse/collection"><gslib:aboutCollectionPageTitle/></xsl:when><xsl:otherwise>Cross-Collection</xsl:otherwise></xsl:choose>
410</xsl:template>
411
412
413
414
415
416<!--
417BERRY BASKET TEMPLATES
418These get used on many different pages to add the
419berry basket function to the site
420-->
421
422<!-- put the drag&drop berry basket on the page -->
423<xsl:template name="berryBasket">
424    <xsl:if test="$berryBasketOn">
425        <div id="berrybasket" class="hide">
426            <span>Berry Basket</span>
427            <span id="berryBasketExpandCollapseLinks" style="display: none;">
428                <a id="berryBasketExpandLink" href="javascript:showBasket()">Expand</a>
429                <a id="berryBasketCollapseLink" style="display: none;" href="javascript:hideBasket()">Collapse</a>
430            </span>
431            <div id="baskethandle"><span><xsl:text> </xsl:text></span></div>
432            <div id ="berries"><span><xsl:text> </xsl:text></span></div>
433        </div>
434    </xsl:if>
435</xsl:template>
436
437<!-- include the required javascript and css for berry baskets -->
438<xsl:template name="berryBasketHeadTags">
439    <script type="text/javascript" src="interfaces/{$interface_name}/js/YAHOO.js"><xsl:text> </xsl:text></script>
440    <script type="text/javascript" src="interfaces/{$interface_name}/js/event.js"><xsl:text> </xsl:text></script>
441    <script type="text/javascript" src="interfaces/{$interface_name}/js/connection.js"><xsl:text> </xsl:text></script>
442    <script type="text/javascript" src="interfaces/{$interface_name}/js/dom.js"><xsl:text> </xsl:text></script>
443    <script type="text/javascript" src="interfaces/{$interface_name}/js/dragdrop.js"><xsl:text> </xsl:text></script>
444    <script type="text/javascript" src="interfaces/{$interface_name}/js/ygDDPlayer.js"><xsl:text> </xsl:text></script>
445    <script type="text/javascript" src="interfaces/{$interface_name}/js/ygDDOnTop.js"><xsl:text> </xsl:text></script>
446    <script type="text/javascript" src="interfaces/{$interface_name}/js/berrybasket.js"><xsl:text> </xsl:text></script>
447    <link rel="stylesheet" href="interfaces/{$interface_name}/style/berry.css" type="text/css"/>
448</xsl:template>
449
450<!--
451create a little berry which can be drag&dropped onto the berry basket
452used on classifier and search result pages
453-->
454<xsl:template name="documentBerryForClassifierOrSearchPage">
455    <xsl:if test="$berryBasketOn">
456        <img class="pick" src="interfaces/{$interface_name}/images/berry.png" alt="in basket" width="15" height="15" border="0">
457            <xsl:attribute name="id"><xsl:value-of select="/page/pageResponse/collection/@name"/>:<xsl:value-of select="@nodeID"/></xsl:attribute>
458        </img>
459    </xsl:if>
460</xsl:template>
461
462<!--
463create little berrys which can be drag&dropped onto the berry basket
464used on the document page
465-->
466<xsl:template name="documentBerryForDocumentPage">
467    <xsl:variable name="selectedNode"><xsl:value-of select="/page/pageResponse/document/@selectedNode"/></xsl:variable>
468    <xsl:variable name="rootNode"><xsl:value-of select="/page/pageResponse/document/documentNode[@nodeType='root']/@nodeID"/></xsl:variable>
469
470    <xsl:if test="$berryBasketOn"> 
471        <div id="documentberries">
472            <img class='pick' id="{/page/pageResponse/collection/@name}:{$rootNode}" src="interfaces/{$interface_name}/images/berry.png" alt="in basket" width="15" height="15" border="0"/>
473            <span id="{/page/pageResponse/collection/@name}:{$rootNode}:root" class="documentberry">the whole document</span>
474
475            <xsl:if test="$selectedNode != $rootNode">
476                <img class='pick'  id="{/page/pageResponse/collection/@name}:{$selectedNode}" src="interfaces/{$interface_name}/images/berry.png" alt="in basket" width="15" height="15" border="0"/>
477                <span id="{/page/pageResponse/collection/@name}:{$selectedNode}:section" class="documentberry">the current section</span>
478            </xsl:if>
479        </div>
480    </xsl:if>
481</xsl:template>
482
483
484<!-- document page -->
485<xsl:template name="documentTitle">
486    <xsl:value-of select="/page/pageResponse/document/documentNode/metadataList/metadata[@name='Title']"/>
487</xsl:template>
488
489
490<xsl:template name="coverImage">
491    <img><xsl:attribute name='src'><xsl:value-of select="/page/pageResponse/collection/metadataList/metadata[@name='httpPath']"/>/index/assoc/<xsl:value-of select="metadataList/metadata[@name='archivedir']"/>/cover.jpg</xsl:attribute></img>
492</xsl:template>
493
494<xsl:template name="previousNextButtons">
495    <!-- prev -->
496    <a>
497        <xsl:attribute name="href"><xsl:value-of select="$library_name"/>?a=d&amp;c=<xsl:value-of select="/page/pageResponse/collection/@name"/>&amp;d=<xsl:value-of select="@selectedNode"/>.pp&amp;sib=1&amp;p.s=<xsl:value-of select='/page/pageRequest/paramList/param[@name="p.s"]/@value'/>&amp;p.sa=<xsl:value-of select='/page/pageRequest/paramList/param[@name="p.sa"]/@value'/>&amp;p.a=<xsl:value-of select='/page/pageRequest/paramList/param[@name="p.a"]/@value'/></xsl:attribute>
498        <img class="lessarrow" src="interfaces/{$interface_name}/images/previous.png"/>
499    </a>
500
501    <!-- next -->
502    <a>
503        <xsl:attribute name="href"><xsl:value-of select="$library_name"/>?a=d&amp;c=<xsl:value-of select="/page/pageResponse/collection/@name"/>&amp;d=<xsl:value-of select="@selectedNode"/>.np&amp;sib=1&amp;p.s=<xsl:value-of select='/page/pageRequest/paramList/param[@name="p.s"]/@value'/>&amp;p.sa=<xsl:value-of select='/page/pageRequest/paramList/param[@name="p.sa"]/@value'/>&amp;p.a=<xsl:value-of select='/page/pageRequest/paramList/param[@name="p.a"]/@value'/></xsl:attribute>
504        <img class="morearrow" src="interfaces/{$interface_name}/images/next.png"/>
505    </a>
506
507</xsl:template>
508
509
510</xsl:stylesheet>
Note: See TracBrowser for help on using the browser.