Subject: RE: Mapping via intermediate XML file problem
From: "Michael Kay" <mike@xxxxxxxxxxxx>
Date: Tue, 1 Apr 2008 22:36:06 +0800
|
> I only need this part of stylesheet to substitute a few
> element names and copy the rest unchanged.
> What should I do then to make the substitution code work on
> the element that are unmatche by the mapping file?
Something like this
<xsl:element name="{($maps[@old = local-name(current())]/@new, @old)[1]}">
The idiom (A,B)[1] means "A if it exists, otherwise B".
Michael Kay
http://www.saxonica.com/
|