Subject: Re: How to show explicitly the implicit sequence constructor?
From: David Carlisle <davidc@xxxxxxxxx>
Date: Sat, 29 Mar 2014 10:38:22 +0000
|
On 29/03/2014 09:28, Costello, Roger L. wrote:
Hi Folks,
In the following template rule is an implicit sequence constructor. The sequence constructor expresses this: "Show the value of Title, then show the value of Author."
<xsl:template match="Book">
<xsl:value-of select="Title" />
<xsl:value-of select="Author" />
</xsl:template>
Is there a way to explicitly show the sequence constructor?
For example, this would be a neat way to explicitly show the sequence constructor:
<xsl:template match="Book">
<xsl:sequence>
<xsl:value-of select="Title" />
<xsl:value-of select="Author" />
</xsl:sequence>
</xsl:template>
Unfortunately that is not legal.
Is there a way to explicitly show the sequence constructor?
/Roger
you could use
<xsl:sequence select="string(Title),string(Author)" separator=""/>
although that's a sequence of strings not a sequence of text nodes, it
possibly comes to the same thing in the end.
David
--
google plus: https:/profiles.google.com/d.p.carlisle
|