[Yanel-commits] rev 26506 -
public/yanel/trunk/src/contributions/resources/nutch/xslt
michi at wyona.com
michi at wyona.com
Mon Aug 6 11:02:53 CEST 2007
Author: michi
Date: 2007-08-06 11:02:52 +0200 (Mon, 06 Aug 2007)
New Revision: 26506
Modified:
public/yanel/trunk/src/contributions/resources/nutch/xslt/result2xhtml.xsl
Log:
group added
Modified: public/yanel/trunk/src/contributions/resources/nutch/xslt/result2xhtml.xsl
===================================================================
--- public/yanel/trunk/src/contributions/resources/nutch/xslt/result2xhtml.xsl 2007-08-06 08:56:07 UTC (rev 26505)
+++ public/yanel/trunk/src/contributions/resources/nutch/xslt/result2xhtml.xsl 2007-08-06 09:02:52 UTC (rev 26506)
@@ -17,7 +17,10 @@
<xsl:param name="localization.language" select="'LOCALIZATION_LANG_IS_NULL'"/>
<xsl:param name="translation.language" select="'TRANSLATION_LANG_IS_NULL'"/>
+ <xsl:param name="group" select="''"/>
+<!--
<xsl:param name="group" select="'GROUP_IS_NULL'"/>
+-->
<xsl:variable name="query" select="/yanel:nutch/yanel:query"/>
<!--
@@ -51,7 +54,7 @@
<body>
<span id="pageInfo" itemsPerPage="{$hitsPerPage}"/>
<div style="text-align:right;font-size:smaller;width:auto;float:right;">
- <a href="?query={$query}&hitsPerPage={$hitsPerPage}&start={number(@yanel:start)}&yanel.resource.viewid=source"><i18n:message key="viewResultsAsXml"/></a>
+ <a href="?query={$query}&hitsPerPage={$hitsPerPage}&start={number(@yanel:start)}&group={$group}&yanel.resource.viewid=source"><i18n:message key="viewResultsAsXml"/></a>
</div>
<form name="search">
<input type="text" name="query" value="{$query}"/>
@@ -135,8 +138,8 @@
<xsl:if test="number(@yanel:totalHits) > 0">
<div id="pagening">
-
<div style="text-align:center;padding-top:12px;">
+ Result Pages:
<xsl:call-template name="makeLinksForPagening">
<xsl:with-param name="pageNo">1</xsl:with-param>
</xsl:call-template>
@@ -146,9 +149,10 @@
</xsl:template>
<xsl:template name="makeLinksForPagening">
- <xsl:param name="pageNo"/>
+ <xsl:param name="pageNo"/>
<xsl:variable name="minPage"><xsl:value-of select="number($currentPageNo - $range - 1)" /></xsl:variable>
<xsl:variable name="maxPage"><xsl:value-of select="number($currentPageNo + $range)" /></xsl:variable>
+
<xsl:if test="number(floor($totalHits div $hitsPerPage)) != 0">
<xsl:if test="number($pageNo - 1) != number(ceiling($totalHits div $hitsPerPage))">
<xsl:choose>
@@ -162,7 +166,7 @@
<xsl:otherwise>
<xsl:if test="number($pageNo) > number($minPage)">
<xsl:if test="number($pageNo) < number($maxPage)">
- <a href="?query={$query}&hitsPerPage={$hitsPerPage}&start={number(number($pageNo - 1) * $hitsPerPage)}&yanel.meta.language={$localization.language}"><xsl:value-of select="$pageNo" /></a> 
+ <a href="?query={$query}&hitsPerPage={$hitsPerPage}&start={number(number($pageNo - 1) * $hitsPerPage)}&group={$group}&yanel.meta.language={$localization.language}"><xsl:value-of select="$pageNo" /></a> 
</xsl:if>
</xsl:if>
</xsl:otherwise>
More information about the Yanel-commits
mailing list