[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

Re: [xsl] node() function

Subject: Re: [xsl] node() function
From: "Abel Braaksma (Exselt) abel@xxxxxxxxxx" <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx>
Date: Tue, 24 Jun 2014 08:55:11 -0000

Dimitre Novatchev dnovatchev@xxxxxxxxx <mailto:xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx>
dinsdag 24 juni 2014 5:06

A shorter "delete-all" template is, of course this:

<xsl:template match="node()"/>

or even shorter:

<xsl:template match="/"/>

With one big exception: both templates do not do apply-templates, meaning that it is not possible to "override" with another template, such as match="text()", to catch a child element or text node. Writing it this way you should only do if you do not plan on processing the children in any way, i.e., if you want to delete everything, including the children of a node.

The course that Dimitre showed is a very good one, with a good pace and clear examples, and the first X or so minutes is free, so you can try first and buy later.


Current Thread