[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: for-each-group
On 28.03.2018 17:53, Rick Quatro rick@xxxxxxxxxxxxxx wrote:
I have a <step> element that looks something like this: Can you explain the rules for that result, do you want to group any adjacent "para" element into one group but keep each "figure" element in its own group? In that case you can use <xsl:for-each-group select="*" group-adjacent="boolean(self::para)"> <xsl:choose> <xsl:when test="current-grouping-key()"> <group> <xsl:apply-templates select="current-group()"/> </group> </xsl:when> <xsl:otherwise> <xsl:for-each select="current-group()"> <group> <xsl:apply-templates select="."/> </group> </xsl:for-each> </xsl:otherwise> </xsl:choose> </xsl:for-each-group>
|
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
|