Show
Ignore:
Timestamp:
09.05.2011 14:37:04 (8 years ago)
Author:
sjm84
Message:

Updating this branch to match the latest Greenstone3 changes

Location:
main/branches/64_bit_Greenstone/greenstone3
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • main/branches/64_bit_Greenstone/greenstone3

  • main/branches/64_bit_Greenstone/greenstone3/web/interfaces/default/transform/util.xsl

    r23336 r24007  
    44  xmlns:gslib="http://www.greenstone.org/XSL/Library" 
    55  xmlns:gsf="http://www.greenstone.org/greenstone3/schema/ConfigFormat" 
    6   xmlns:util="http://org.greenstone.gsdl3.util.XSLTUtil" 
    7   exclude-result-prefixes="util gslib gsf"> 
     6  exclude-result-prefixes="gslib gsf"> 
    87   
    98  <!-- some global parameters - these are set by whoever is invoking the transformation --> 
     
    1110  <xsl:param name="library_name"/> 
    1211 
     12  <!-- Get rid of XSLT parameters from view --> 
     13  <xsl:template match="xsltparams/param"> 
     14    <xsl:text></xsl:text> 
     15  </xsl:template> 
     16   
    1317  <!-- every pages ................................................. --> 
    1418   
     
    6064      hide_link = document.getElementById("hide"); 
    6165      removeAllChildren(hide_link); 
    62       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">")); 
     66      var theText = getText('hide_error', null); 
     67      var hide_text = document.createTextNode(theText); 
     68      hide_link.appendChild(hide_text)); 
    6369      } else { 
    6470      obj.style.display = "none"; 
    6571      hide_link = document.getElementById("hide"); 
    6672      removeAllChildren(hide_link); 
    67       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">")); 
     73      var theText = getText('show_error', null); 
     74      var show_text = document.createTextNode(theText); 
     75      hide_link.appendChild(show_text); 
    6876      }  
    6977      } 
    7078    </xsl:text> 
    7179      </script> 
    72       <p align='right'><a id="hide" href="javascript:toggleHideError(error);"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'show_error')"/></a></p> 
     80      <p align='right'><a id="hide" href="javascript:toggleHideError(error);"></a></p> 
    7381      <div id="error" style="display: none;"> 
    7482    <xsl:apply-templates select="descendant::error"/> 
     
    8492   
    8593  <xsl:template name="poweredByGS3TextBar"> 
    86     <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'gs3power')"/>  
     94    <span class="getTextFor gs3power">&amp;nbsp;</span> 
    8795  </xsl:template> 
    8896   
     
    92100  <xsl:template name="siteHomePageTitle"> 
    93101    <!-- put a space in the title in case the actual value is missing - mozilla will not display a page with no title--> 
    94     <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'gsdl')"/><xsl:text> </xsl:text> 
     102    <span class="getTextFor gsdl">&amp;nbsp;</span><xsl:text> </xsl:text> 
    95103  </xsl:template> 
    96104 
    97105 
    98106  <xsl:template name="selectACollectionTextBar"> 
    99     <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home.select_a_collection')"/> 
     107    <span class="getTextFor home.select_a_collection">&amp;nbsp;</span> 
    100108  </xsl:template> 
    101109   
     
    112120      <input type="hidden" name="s1.collection" value="all"/> 
    113121      <input type="text" name="s1.query" size="20"/> 
    114       <input type="submit"><xsl:attribute name="value"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home.quick_search')"/></xsl:attribute></input> 
     122      <input type="submit" class="getTextFor null this.value.home.quick_search" /> 
    115123    </form> 
    116124  </xsl:template> 
     
    162170   
    163171  <xsl:template name="libraryInterfaceLink"> 
    164     <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> 
     172    <li><a href="{$library_name}?a=p&amp;sa=gli4gs3"><span class="getTextFor home.librarian_interface">&amp;nbsp;</span></a></li> 
    165173  </xsl:template>  
    166    
    167    
    168   <xsl:template name="greenstoneLogoAlternateText"> 
    169     <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'gsdl')"/> 
    170   </xsl:template> 
    171174 
    172175  <!-- about page - collection home ......................... --> 
     
    177180  <xsl:variable name="this-service" select="/page/pageResponse/service/@name"/> 
    178181 
    179  
    180182  <xsl:template name="aboutCollectionPageTitle"> 
    181183    <!-- put a space in the title in case the actual value is missing - mozilla will not display a page with no title--> 
     
    188190      <xsl:choose> 
    189191    <xsl:when test="$this-element/displayItem[@name='icon']"> 
    190       <img border="0"> 
     192      <img border="0" class="getTextFor null this.title.aboutpage"> 
    191193        <xsl:attribute name="src"> 
    192194          <xsl:value-of select="$this-element/metadataList/metadata[@name='httpPath']"/>/images/<xsl:value-of select="$this-element/displayItem[@name='icon']"/> 
     
    194196        <xsl:attribute name="alt"> 
    195197          <xsl:value-of select="$this-element/displayItem[@name='name']"/> 
    196         </xsl:attribute> 
    197         <xsl:attribute name="title"> 
    198           <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'aboutpage')"/> 
    199198        </xsl:attribute> 
    200199      </img> 
     
    209208 
    210209  <xsl:template name="homeButtonTop"> 
    211     <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> 
    212       <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'home_b')"/></a> 
     210    <a href="{$library_name}?a=p&amp;sa=home" class="getTextFor home_b this.title.home_tip">&amp;nbsp;</a> 
    213211  </xsl:template> 
    214212 
     
    217215    <xsl:choose> 
    218216      <xsl:when test="$pageType='help'"> 
    219     <li><a><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_b')"/></a></li> 
    220       </xsl:when> 
    221       <xsl:otherwise> 
    222     <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> 
    223         <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'help_b')"/> 
    224       </a></li> 
     217    <li><a class="getTextFor help_b"></a></li> 
     218      </xsl:when> 
     219      <xsl:otherwise> 
     220    <li><a href="{$library_name}?a=p&amp;sa=help&amp;c={$collName}" class="getTextFor help_b this.title.help_tip">&amp;nbsp;</a></li> 
    225221      </xsl:otherwise> 
    226222    </xsl:choose> 
     
    231227    <xsl:choose> 
    232228      <xsl:when test="$pageType='pref'"> 
    233     <li><a><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_b')"/></a></li> 
    234       </xsl:when> 
    235       <xsl:otherwise> 
    236     <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> 
    237         <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'pref_b')"/> 
    238       </a></li> 
     229    <li><a class="getTextFor pref_b">&amp;nbsp;</a></li> 
     230      </xsl:when> 
     231      <xsl:otherwise> 
     232    <li><a href="{$library_name}?a=p&amp;sa=pref&amp;c={$collName}" class="getTextFor pref_b this.title.pref_tip">&amp;nbsp;</a></li> 
    239233      </xsl:otherwise> 
    240234    </xsl:choose> 
     
    279273  <xsl:template match="serviceList"> 
    280274    <xsl:param name="collName"/> 
    281     <h3><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'about.services')"/></h3> 
     275    <h3 class="getTextFor about.services">&amp;nbsp;</h3> 
    282276    <xsl:choose> 
    283277      <xsl:when test="service"> 
    284     <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'about.servicehelp')"/> 
    285       </xsl:when> 
    286       <xsl:otherwise> 
    287     <xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'about.noservices')"/> 
     278        <span class="getTextFor about.servicehelp">&amp;nbsp;</span> 
     279      </xsl:when> 
     280      <xsl:otherwise> 
     281        <span class="getTextFor about.noservices">&amp;nbsp;</span> 
    288282      </xsl:otherwise> 
    289283    </xsl:choose>