xsl-list
[Top] [All Lists]

Re: [xsl] xsl:namespace

2009-02-20 12:33:19
I use the xsi:type example because that is the one we have in the
spec, http://www.w3.org/TR/xslt20/#element-namespace, and the one
Michael Kay is using in "XSLT 2,0 and XPath 2.0", 4th Edition, page
392. But the problem with the examples in the spec and MK are, that
xsl:namespace is not really needed. The spec admits that an
xsl:element example would have been more appropriate.

So I kept the literal not so good example of spec and MK as
alternative 2 but I removed xsl:namespace. Then I added an example
with xsl:element, alternative 1,  and I added a dynamic one,
alternative 3.

But the two proposals of Florent and Vladimir are basically the
literal example one more time where xsl:namespace is not needed unless
in a dynamic solution as in my alternative 3. We could make Vladimir's
dynamic but it will not make it less artificial or confusing than my
own example. Instead of the xsi namespace we will get some other
namespace.

So wee still need some good examples of why xsl:namespace can be
necessary. I have provided a dynamic one where it is necessary, and
one using xsl:element, where xsl:namespace is also necessary if
xsl:element must be used (we might e.g. need to compute the name of
the element).


Cheers,
Jesper Tverskov

http://www.xmlkurser.dk
http://www.xmlplease.com

--~------------------------------------------------------------------
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>