[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Re: Adjacent grouping?
On 19.11.2017 14:38, rus tle profrustyleafiii@xxxxxxxxxxx wrote:
Hi Michael, You could adjust the iteration and the value selection with e.g. <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:math="http://www.w3.org/2005/xpath-functions/math" exclude-result-prefixes="xs math" version="3.0"> <xsl:strip-space elements="*"/> <xsl:output indent="yes"/> <xsl:template match="root"> <xsl:copy> <xsl:iterate select="p"> <xsl:param name="previous" as="xs:integer?" select="()"/> <xsl:choose> <xsl:when test="empty($previous) or xs:integer(Content/@value) gt $previous+30"> <xsl:copy-of select="."/> <xsl:next-iteration> <xsl:with-param name="previous" select="Content/@value"/> </xsl:next-iteration> </xsl:when> <xsl:otherwise> <xsl:copy> <xsl:copy-of select="@*"/> <Content value=""/> </xsl:copy> </xsl:otherwise> </xsl:choose> </xsl:iterate> </xsl:copy> </xsl:template> </xsl:stylesheet>
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|