RE: [xsl] Can you break one node tree into two?

Subject: RE: [xsl] Can you break one node tree into two?
From: "Wilde Rebecca L SSgt HQ SSG/STS" <Rebecca.Wilde@xxxxxxxxxxxxx>
Date: Tue, 1 Feb 2005 10:52:20 -0600
Thank you for all the responses!  Working with those I was able to come
up with and was able to get to work:

<xsl:template match="RootEle">
	<xsl:if test="*/Address">
			<xsl:apply-templates mode="Addressing"/>
		<xsl:apply-templates mode="Message"/>

<xsl:template match="RootEle/*" mode="Addressing">
	<xsl:variable name="a" select="Address"/>
		<xsl:copy-of select="$a | $a/preceding-sibling::*"/>

<xsl:template match="RootEle/*" mode="Message">
	<xsl:variable name="b" select="Address"/>
		<xsl:when test="$b">
		<xsl:otherwise><xsl:copy-of select="."/></xsl:otherwise>

This will take into account if I did not get an "Address" node as well
as not force me to know what any node is besides the "RootEle" and

Thank you all for the help.  Now I just have to see how well I can
continue to tweak.


Current Thread