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

NEW2!!!showing HTML data in XML files using XSL!!!

Subject: NEW2!!!showing HTML data in XML files using XSL!!!
From: Rosa I-Ting Cheng <Rosa@xxxxxxxxxxxxx>
Date: Fri, 6 Apr 2001 12:14:20 +1000
showing data as xml file
what if the HTML text is between <![CDATA[text is <I>here</I>]]> in the XML
file?
how can I copy that section and display as HTML normally.  Cos at the
moment, I get something like this:
text is <I>here</I>
on the browser, the XSL seem to have changed the '<' and '>' into &lt; and
&gt;


-----Original Message-----
From: Mike Brown [mailto:mike@xxxxxxxx]
Sent: Friday, 30 March 2001 3:48 PM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: Re:  !!!showing HTML data in XML files using XSL!!!


Rosa I-Ting Cheng wrote:
> XML:
> <root>
> <text><I><B>here is some info</B></I></text>
> </root>
> 
> in XSL I'll be using <xsl:value-of select="root/text"/> to show the info.

Why won't you be using <xsl:copy-of select="root/text"/> ?

xsl:copy-of means
  1. create a copy of the current node in the result tree
  2. create copies of all its descendant nodes as well

This is what you want. Don't use CDATA sections. If you really wanted to use
them, you would use them in your XML, not your XSL, and you would be
changing
the meaning of what is inside your <text> element.

 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.