This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: Carrying Namespaces through a XSL to XSL Transformation


> If I understand correctly, this is basically caused by the 
> fact that, in the
> desired generated XSLT, the namespace declaration is only 
> required because
> the prefix appears in XPath expressions, but not in a literal result
> element.
> 
> Seems to me that this is a hole that should be closed in XSLT 
> 1.1... (or is it?).
> 
The draft XSLT 1.1 (and indeed the draft XSLT 1.0 errata) defines semantics
for xsl:copy and xsl:copy-of when applied to a namespace node; this was
previously undefined. Essentially the namespace node is copied provided
there is no conflict with existing namespace nodes. This allows you to put a
namespace node on a result element that was not present on the element that
the result element was created from. The only constraint is that the
namespace declaration must be present somewhere in the source document, but
you can get round this if you're determined by using a result tree fragment
as an additional source document.

Mike Kay

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]