Reputation: 17488
When using XSL what is the difference between
<xsl:apply-templates select="./*"/>
and
<xsl:apply-templates />
The former does not appear to bring in any text after a child element.
Upvotes: 7
Views: 1151
Reputation: 163595
Correct. "*"
or "./*"
selects the child elements of the context node. But "node()"
or "./node()"
selects all the children including elements, text nodes, comments, and processing instructions. The default for xsl:apply-templates is select="node()".
Upvotes: 13