xsl-list
[Top] [All Lists]

Re: XMLNS attribute in the XML source file

2003-07-01 14:07:14


This is a FAQ.

namespace declarations are not attributes in the Xpath model, they are
just syntax for part of the name, so by adding a namespace declaration
you are changing the name of your elements from
test in no namespace to
test in http:\\nowhere\schema\test
(which incidentally isn't a legal URI, not that an XSLT system will care)

your stylesheet matches elements called
test in no namespace
so no longer matches.

add
xmlns:x="http:\\nowhere\schema\test" to your stylesheet element
and then use x:test,  x:test2  etc in your stylesheet.

I'm sure the FAQ for this list will have some entries about this (it
ought to have)

David

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



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