source: greenstone3/trunk/web/interfaces/classic/transform/help-common.xsl@ 14585

Last change on this file since 14585 was 14585, checked in by qq6, 16 years ago

only count the first list of classifierlist

  • Property svn:keywords set to Author Date Id Revision
File size: 2.8 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<xsl:stylesheet version="1.0"
3 xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
4 xmlns:java="http://xml.apache.org/xslt/java"
5 xmlns:util="xalan://org.greenstone.gsdl3.util.XSLTUtil"
6 extension-element-prefixes="java util"
7 exclude-result-prefixes="java util">
8
9
10 <xsl:template match="collection" mode="simplehelp">
11 <xsl:variable name="longCollName"><xsl:value-of select="displayItem[@name='name']" disable-output-escaping='yes'/></xsl:variable>
12 <!--<xsl:variable name="numoptions">5</xsl:variable>-->
13 <xsl:variable name="has_search"><xsl:choose><xsl:when test="serviceList/service[@name='TextQuery']">1</xsl:when><xsl:otherwise>0</xsl:otherwise></xsl:choose></xsl:variable>
14 <xsl:variable name="has_phrase"><xsl:choose><xsl:when test="serviceList/service[@name='PhindApplet']">1</xsl:when><xsl:otherwise>0</xsl:otherwise></xsl:choose></xsl:variable>
15 <xsl:variable name="numoptions" select="count(serviceList/service[@name='ClassifierBrowse']/classifierList[position() mod 2 = 1]/classifier)"/>
16 <h3><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help.simplehelpheading', $longCollName)"/></h3>
17 <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help.numbrowseoptions', $numoptions+$has_search+$has_phrase)"/>
18 <ul>
19 <xsl:if test="$has_search =1">
20 <li><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help.Searchshort')" disable-output-escaping='yes'/></li>
21 </xsl:if>
22 <xsl:for-each select="serviceList/service[@name='ClassifierBrowse']/classifierList/classifier">
23 <xsl:variable name="title">help.<xsl:value-of select="@content"/>short</xsl:variable>
24 <li><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, $title)" disable-output-escaping='yes'/></li>
25 </xsl:for-each>
26 <xsl:if test="$has_phrase =1">
27 <li><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help.Phraseshort')" disable-output-escaping='yes'/></li>
28 </xsl:if>
29 </ul>
30 <xsl:if test="$has_search =1">
31 <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help.Searchlong')" disable-output-escaping='yes'/>
32 </xsl:if>
33 <xsl:for-each select="serviceList/service[@name='ClassifierBrowse']/classifierList[position() mod 2 = 1]/classifier">
34 <xsl:variable name="title">help.<xsl:value-of select="@content"/>long</xsl:variable>
35 <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, $title)" disable-output-escaping='yes'/>
36 </xsl:for-each>
37 <xsl:if test="$has_phrase =1">
38 <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help.Phraselong')" disable-output-escaping='yes'/>
39 </xsl:if>
40
41 </xsl:template>
42
43
44</xsl:stylesheet>
Note: See TracBrowser for help on using the repository browser.