xsl-list
[Top] [All Lists]

Re: [xsl] I need to make sure that all namespace declarations get output to a particular element, not the document element

2007-03-22 06:59:32

Not sure if the processor is allowed to, I think it is, to cleanup the
namespaces the way it likes and instead  put the namespace decl. to
'test:other-ns-now' element.  

That wouldn't be allowed, The XSLT1 output serialisation is allowed to
move declarations up the tree, meaning a namespace is in scope earlier
than one might expect, but it can never move a namespace declaration
down the tree.  If an element node in the result has a namespace node
(even if that namespace is not used in any element or attribute) the
namespace declaration must be serialised on the element or an ancestor.

The XSLT2 rules are rather different (as namesdpace fixup is part of tree
construction, not part of serialisation) but come to the same result
as far as this point goes.

David

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--

<Prev in Thread] Current Thread [Next in Thread>