Changeset 31238

Show
Ignore:
Timestamp:
15.12.2016 10:16:26 (3 years ago)
Author:
kjdon
Message:

added option disableSearchTermHighlighting=true so the user can switch this behaviour off

Location:
main/trunk/greenstone3/web/interfaces/default/transform
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone3/web/interfaces/default/transform/layouts/toc.xsl

    r30774 r31238  
    286286                 
    287287                <!-- Highlight on/off button --> 
    288                 <xsl:if test="util:contains(/page/pageRequest/paramList/param[@name = 'p.s']/@value, 'Query') and not(metadataList/metadata[@name='NoText'])"> 
     288                <xsl:if test="util:contains(/page/pageRequest/paramList/param[@name = 'p.s']/@value, 'Query') and not(metadataList/metadata[@name='NoText']) and not(/page/pageResponse/format[@type='display']/gsf:option[@name='disableSearchTermHighlighting']/@value='true')"> 
    289289                    <li> 
    290290                        <xsl:attribute name="title"><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'doc.highlightTooltip')"/></xsl:attribute> 
  • main/trunk/greenstone3/web/interfaces/default/transform/pages/document.xsl

    r31049 r31238  
    495495    <xsl:template name="displayAnnotation"> 
    496496        <xsl:choose> 
    497             <xsl:when test="/page/pageRequest/paramList/param[@name = 'hl']/@value = 'off'"> 
     497            <xsl:when test="/page/pageRequest/paramList/param[@name = 'hl']/@value = 'off' or /page/pageResponse/format[@type='display']/gsf:option[@name='disableSearchTermHighlighting']/@value='true')"> 
    498498                <span class="noTermHighlight"><xsl:value-of select="."/></span> 
    499499            </xsl:when>