Ignore:
Timestamp:
2004-11-24T16:43:25+13:00 (19 years ago)
Author:
kjdon
Message:

moved the home,help,pref button code into a separate template called top-buttons

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl3/web/interfaces/classic/transform/style.xsl

    r8539 r8662  
    106106    </td>
    107107    <td align="right">
    108       <table cellspacing='4'>
    109         <tr>
    110           <td class="gsbutton">
    111         <a class="gsbutton" href="{$library_name}?a=p&amp;sa=home">
    112           <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home_b')"/>
    113         </a>
    114           </td>
    115 <!--          <xsl:choose>
    116         <xsl:when test="$pageType='help'">
    117           <td class="gsbuttonoff">
    118             <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_b')"/>
    119           </td>
    120         </xsl:when>
    121         <xsl:otherwise>
    122           <td class="gsbutton">
    123             <a class="gsbutton" href="{$library_name}?a=p&amp;sa=help&amp;c={$collName}">
    124               <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_b')"/>
    125             </a>
    126           </td>
    127         </xsl:otherwise>
    128           </xsl:choose>-->
    129           <xsl:choose>
    130         <xsl:when test="$pageType='pref'">
    131           <td class="gsbuttonoff">
    132             <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_b')"/>
    133           </td>
    134         </xsl:when>
    135         <xsl:otherwise>
    136           <td class="gsbutton">
    137             <a class="gsbutton" title="xxpref" href="{$library_name}?a=p&amp;sa=pref&amp;c={$collName}">
    138               <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_b')"/>
    139             </a>
    140           </td>
    141         </xsl:otherwise>
    142           </xsl:choose>
    143         </tr>
    144       </table>
     108      <xsl:call-template name="top-buttons">
     109        <xsl:with-param name="collName" select="$collName"/>
     110        <xsl:with-param name="pageType" select="$pageType"/>
     111      </xsl:call-template>
    145112    </td>
    146113      </tr>
     
    163130  </xsl:template>
    164131 
    165 
     132  <xsl:template name="top-buttons">
     133    <xsl:param name="collName"/>
     134    <xsl:param name="pageType"/>
     135    <table cellspacing='4'>
     136      <tr>
     137    <td class="gsbutton">
     138      <a class="gsbutton" 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>
     139        <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home_b')"/>
     140      </a>
     141    </td>
     142    <!--          <xsl:choose>
     143    <xsl:when test="$pageType='help'">
     144    <td class="gsbuttonoff">
     145    <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_b')"/>
     146      </td>
     147      </xsl:when>
     148    <xsl:otherwise>
     149    <td class="gsbutton">
     150    <a class="gsbutton" 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>
     151    <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_b')"/>
     152      </a>
     153      </td>
     154      </xsl:otherwise>
     155      </xsl:choose>-->
     156    <xsl:choose>
     157      <xsl:when test="$pageType='pref'">
     158        <td class="gsbuttonoff">
     159          <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_b')"/>
     160        </td>
     161      </xsl:when>
     162      <xsl:otherwise>
     163        <td class="gsbutton">
     164          <a class="gsbutton" 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>
     165        <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_b')"/>
     166          </a>
     167        </td>
     168      </xsl:otherwise>
     169    </xsl:choose>
     170      </tr>
     171    </table>
     172  </xsl:template>
     173 
    166174  <xsl:template name="navigationBar">
    167175    <xsl:param name="collName"/>
Note: See TracChangeset for help on using the changeset viewer.