[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Problem reading root element in XML Stylesheet bas

Subject: Re: Problem reading root element in XML Stylesheet basedXML document
From: Elliotte Rusty Harold <elharo@xxxxxxxxxxxxxxx>
Date: Fri, 31 Jan 2003 13:29:08 -0500
bas company reading
At 6:06 PM -0500 1/31/03, Chris Libby wrote:
I am having a problem reading the root element when performing an XSL
Transformation on an XML file that is based on an XML Schema. The
transformation is successful, however, if I base the XML document on a DTD
file instead.


The problem is not what you think it is. You're trying to match an Order element in no namespace. You need to match an Order element in the publicid:org.xCBL:schemas/XCBL35/Order.xsd namespace.


For example,

<xsl:template xmlns:cd="publicid:org.xCBL:schemas/XCBL35/Order.xsd"; match="cd:Order">
<xsl:text>Print this text if the root element is matched</xsl:text>
</xsl:template>


(You should also use a real URL as a namespace URI. The publicid scheme is not registered with the IANA. )
--


+-----------------------+------------------------+-------------------+
| Elliotte Rusty Harold | elharo@xxxxxxxxxxxxxxx | Writer/Programmer |
+-----------------------+------------------------+-------------------+
|           Processing XML with Java (Addison-Wesley, 2002)          |
|              http://www.cafeconleche.org/books/xmljava             |
| http://www.amazon.com/exec/obidos/ISBN%3D0201771861/cafeaulaitA  |
+----------------------------------+---------------------------------+
|  Read Cafe au Lait for Java News:  http://www.cafeaulait.org/      |
|  Read Cafe con Leche for XML News: http://www.cafeconleche.org/    |
+----------------------------------+---------------------------------+

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


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.