xsl-list
[Top] [All Lists]

RE: [xsl] Sort before paging

2006-08-29 06:52:36
Unfortunately XSLT 1.0 doesn't allow you to do a two-phase transformation in
this way. This would work on XSLT 2.0, or it would work on XSLT 1.0 if your
processor supports an xx:node-set() extension function (which most do, a
notable exception being the Transformiix processor used in Mozilla/Firefox).
Use it like this:

<xsl:template name="positionfilter">
<xsl:param name="sortedlist"/>
<xsl:for-each select="xx:node-set($sortedlist)/*[(position() &gt;= $start)
and
...

after binding the namespace prefix xx (or you own choice of prefix) to the
appropriate namespace URI for the XSLT processor you are using.

Michael Kay
http://www.saxonica.com/


--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--

<Prev in Thread] Current Thread [Next in Thread>