Re: [xsl] Conditional extraction of data

Subject: Re: [xsl] Conditional extraction of data
From: Geert Josten <Geert.Josten@xxxxxxxxxxx>
Date: Wed, 10 Nov 2004 07:12:09 +0100
Wendell Piez wrote:

Depends on what you mean by content. The default templates preserve the character data of the data file. Note that this includes character data in attributes, though you are not using them currently.

Unless I mistake your meaning: almost but not quite.

No, you actually didn't mistake my meaning, though my words can be interpreted the both ways. Attributes are not processed by default (I tested it ;), though the default template for atts indeed preserves the character data..


Thanks for the rectification.

I have the habit of _always_ including identity templates as 'defaults' at the top of my script, so no one get confused by implicit ones. Most of the time, I'm doing conversion stuff and you don't want to lose structure by default then. :-P

(And yes, I tend to use select="@*|node()" also...)

Though I regret it is difficult to specify your own 'defaults' for templates with a mode. You have to explicitly mention the mode and cannot use a wildcard or something. Something for XSLT 2?

Grtz,
Geert

Current Thread