Re: Generating namespace declarations given a result tree?
On Thu, 18 May 2000 12:18:58 +0700 James Clark <jjc@xxxxxxxxxx> wrote: > John-Paul Sicotte wrote: > XSLT says you're supposed to output a tree T so that if you parsed it > back in again and constructed a tree using the XSLT data mdel you would > get a tree T' that was the same as T except that > > - the order of attributes in T' and T may be different > - T' may have namespace nodes that are not in T I read this several times before I sent the mail but one critical thing never clicked in: the tree must be the same including the namespace nodes. I was always wondering what "the same" meant with regards to elements (ie. what about prefixes) but if the namespaces nodes must be the same all of this becomes clear. > In this specific case, if you didn't output the namespace declarations > for jpns[1-3] then T would have namespace nodes that T' did not. That's > not one of the differences that's allowed: XSLT only allows the > converse. So you must output the namespace declarations for jpns[1-3]. If the namespace nodes need to be the same then the prefixes must remain as well. > If XSLT didn't do this, it would be difficult to use XSLT to transform > XSLT stylesheets. Or anything that used xpath expressions as attribute values which was my direct concern. > James Thanks very much John-Paul ---------------------- John-Paul Sicotte Software Composer MessagingDirect mailto:John-Paul@xxxxxxxxxxxxxxxxxxx XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
PURCHASE STYLUS STUDIO ONLINE TODAY!
Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!
Download The World's Best XML IDE!
Accelerate XML development with our award-winning XML IDE - Download a free trial today!
Subscribe in XML format