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

RE: Testing for CDATA

Subject: RE: Testing for CDATA
From: "Josh Canfield" <Josh.Canfield@xxxxxxxxxxxx>
Date: Mon, 8 Mar 2004 17:48:18 -0800
cdata test
>From http://www.dpawson.co.uk/xsl/sect2/cdata.html#d2421e192

3.  How to test for a CDATA section
 
 Mike Kay

No, text in a CDATA section looks exactly the same to the XSLT processor as text outside a CDATA section. For example, 

<![CDATA[xxx]]> looks exactly like xxx
<![CDATA[<>]]> looks exactly like &lt;&gt;

This is because they are intended to be equivalent ways of writing the same thing. 

Josh

-----Original Message-----
From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx
[mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx]On Behalf Of Todd Baker
Sent: Monday, March 08, 2004 5:13 PM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject:  Testing for CDATA


Hi all,

We are making some changes to our CMS and I am having some difficulty
testing for CDATA sections. In a effort to reduce server load on very large
xml files (up to 100mb) we are toying with storing HTML data within cdata
tags (opinions on this are welcome too). 

I am trying to test for either of the following XML types.

1.
<asset id="12">
	<element_title>Test Page Title</element_title>
	<element_content>
		<html>
			<b>Content For the test page</b><br />
		</html>
	</element_content>
</asset>

2.
<asset id="12">
	<element_title>Test Page Title</element_title>
	<element_content>
		<html>
			<![CDATA[
			<b>Content For the test page</b><br />
			]]>	
		</html>
	</element_content>
</asset>

Is it possible to test for the presence of a cdata section in a xsl:choose ?

Thanks in advance.

Todd



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


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


Current Thread
  • Testing for CDATA
    • Todd Baker - Mon, 8 Mar 2004 20:14:07 -0500 (EST)
      • <Possible follow-ups>
      • Josh Canfield - Mon, 8 Mar 2004 20:49:01 -0500 (EST) <=
        • Todd Baker - Mon, 8 Mar 2004 20:56:52 -0500 (EST)

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.