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

Re: Result tree fragment to string? result as CDATA

Subject: Re: Result tree fragment to string? result as CDATA
From: "Andrew Welch" <andrew.j.welch@xxxxxxxxx>
Date: Thu, 28 Aug 2008 16:48:05 +0100
Re:  Result tree fragment to string? result as CDATA
> Specifically,  I'm trying to generate an output document with a
> description
> element that looks like this
>
> ... other markup in result document...
> <description><![CDATA[
>              <html>
>                <head>
>                  <title>this is a test</title>
>                </head>
>                <body>
>                  <b>this is a test</b>
>                </body>
>              </html>]]>
> </description>
> ... more result document here ...
>
> The solutions I've seen thus far all seem to end up with the markup
> escaped.
>
> I specifically don't want the markup to be escaped, but I do want
> the <description> element to have an xs:string value.  Is there any way
> to
> achieve this?
>

If you want a cdata section in the output, then you can use
@cdata-section-elements on xsl:output:

http://www.w3.org/TR/xslt20/#element-output

If you have a cdata section in your input that you want to treat as
markup then you can use lexev:

http://andrewjwelch.com/lexev

If it's neither of those, then post small complete runnable samples :)


-- 
Andrew Welch
http://andrewjwelch.com
Kernow: http://kernowforsaxon.sf.net/

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-2007 All Rights Reserved.