Ignore:
Timestamp:
2015-07-21T05:26:46+12:00 (9 years ago)
Author:
Georgiy Litvinov
Message:

While using Solr field highlighted by Solr Servlet. Also added snippets to search results while using Solr.

Location:
main/trunk/greenstone3/web/interfaces/default
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone3/web/interfaces/default/style/core.css

    r29978 r30049  
    147147#searchResultsStatusBar {
    148148    text-align:center;
     149}
     150
     151.HighlightSnippet {
     152    font-size:0.7em;
    149153}
    150154
     
    208212    background:yellow;
    209213}
     214.snippetText{
     215        font-weight:bold;
     216        font-style:italic;
     217}
     218
    210219
    211220#viewAndZoomOptions {
  • main/trunk/greenstone3/web/interfaces/default/transform/pages/query.xsl

    r29553 r30049  
    136136                          <xsl:call-template name="documentBerryForClassifierOrSearchPage"/>
    137137                        </td>
    138 
     138                        <xsl:call-template name="highlightSnippet">
     139                            <xsl:with-param name="nodeHASH">
     140                                <xsl:value-of select="@nodeID"/>
     141                            </xsl:with-param>
     142                        </xsl:call-template>
    139143                        <xsl:call-template name="documentNodePost"/>
    140144                    </tr>
     
    153157    </xsl:template>
    154158
     159    <xsl:template name="highlightSnippet">
     160        <xsl:param name="nodeHASH">
     161        </xsl:param>
     162        <xsl:for-each select="/page/pageResponse/highlightSnippetList/highlightSnippet[@nodeID = $nodeHASH]">
     163                        <tr>
     164                            <td>
     165                                </td>
     166                                <td>
     167                                    <div class="HighlightSnippet">
     168                                        <xsl:value-of select="." disable-output-escaping="yes"/>
     169                                    </div>
     170                            </td>
     171                    </tr>
     172            </xsl:for-each>
     173    </xsl:template>
    155174    <xsl:template name="queryPage">
    156175        <xsl:for-each select="pageResponse/service">
Note: See TracChangeset for help on using the changeset viewer.