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

RE: XSL to output new XML document with root node

Subject: RE: XSL to output new XML document with root node
From: "Michael Kay" <mike@xxxxxxxxxxxx>
Date: Tue, 2 May 2006 10:00:29 +0100
xsl in output xml stylesheet
> Hi.  I have an XSL sheet to extract certain data from an XML 
> document.  I use Saxon for the transform and have the output 
> as XML.  I need to have the outputted XML document to contain 
> a root node.  How do I code the XSL sheet to create the root 
> node for the XML output document?  The purpose is so I am 
> able to run a different XSL transform on the output XML 
> document.  Thanks.

As Ken explained, your terminology is confused, which makes it difficult to
understand your problem. I'm wondering though, perhaps what you are trying
to do is to generate an <?xml-stylesheet?> processing instruction in the
output? If so, you can do that with an <xsl:processing-instruction> element
in the stylesheet. However, unless the next transformation is to run in a
browser, this isn't the way I would normally implement stylesheet chaining:
I would fire off the sequence of transformations from some controlling
application, written in Java, Ant, shell-script, or a pipeline language,
depending on the environment.

Michael Kay
http://www.saxonica.com/

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.