Re: [xsl] matching positional nodes

Subject: Re: [xsl] matching positional nodes
From: "Joris Gillis" <roac@xxxxxxxxxx>
Date: Thu, 07 Jul 2005 19:31:38 +0200
Hi,

Tempore 18:48:48, die 07/07/2005 AD, hinc in xsl-list@xxxxxxxxxxxxxxxxxxxxxx scripsit Spencer Tickner <spencertickner@xxxxxxxxx>:

<xsl:template match="section">
<section>
<sectionnumber><xsl:apply-templates select="BOLD[1]"/></sectionnumber>
<sectiontext><xsl:apply-templates select="*[not(BOLD[1])]"/></sectiontext>
</section>
</xsl:template>



Try 'BOLD[1]/following-sibling::node()'
This will select all nodes (elements, text or other) that follow after the first 'BOLD' element.


Your original try '*[not(BOLD[1])]' selects all element nodes (no text nodes) that don't have a 'BOLD' child element; not quite what you meant...



regards,
--
Joris Gillis (http://users.telenet.be/root-jg/me.html)
Spread the wiki (http://www.wikipedia.org)

Current Thread