Subject: Re: Templates aplied to namespaces From: David Carlisle <davidc@xxxxxxxxx> Date: Sun, 19 Dec 1999 20:08:14 GMT |
I have an input document that looks like this: <?xml version="1.0" encoding="UTF-8" ?> <ROOTELEMENT xmlns="http://www.somewhere.com/mynamespace"> <ERRORCODE>0</ERRORCODE> <BOOKLIST> That is the same input document as this: <?xml version="1.0" encoding="UTF-8" ?> <x:ROOTELEMENT xmlns:x="http://www.somewhere.com/mynamespace"> <x:ERRORCODE>0</x:ERRORCODE> <x:BOOKLIST> That is, an XSLT engine sees the same input tree in either case. It is probably simpler to think of the latter syntax rather than the former when writing the stylesheet, even if you know all the actual documents are in the first form. so <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0" xmlns:x="http://www.somewhere.com/mynamespace" > <xsl:template match="x:BOOKLIST"> ... <xsl:for-each select="x:ERRORCODE"> ... David XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Templates aplied to namespaces, Elliotte Rusty Harol | Thread | Re: Templates aplied to namespaces, Mark D. Anderson |
Do you know how to refer to a node?, Jonathan Asbell | Date | Re: Do you know how to refer to a n, John Robert Gardner |
Month |