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

Re: ACCESSING SPECIFIC CDATA FIELD

Subject: Re: ACCESSING SPECIFIC CDATA FIELD
From: drkm <darkman_spam@xxxxxxxx>
Date: Tue, 13 Dec 2005 18:28:41 +0100 (CET)
Re:  ACCESSING SPECIFIC CDATA FIELD
viniciuscamara@xxxxxxxxxxxx wrote:

> Thanks Jon and friends,

  What about sisters ?-)

> for your explanation about CDATA nodes.

> Well, I tried to use your idea "<xsl:value-of
> select="text()[1]" />" to access the text inside the node
> <etp id="200"> (see the code bellow), and spected this
> return: "Trying accessing only this", but returned empty
> to me.

> >        <etp id="200">
> >            <![CDATA[Trying accessing only this]]>
> >            <nvgs>

  Maybe your parser makes a text node for "\n ", between the
'etp' element and the CDATA section, and an other text node
for the cntent of the CDATA section itself.  I think it has
to merge all the text in 'etp' before the 'nvgs' element in
one single text node.

  Can someone confirm this?

  What produces <xsl:value-of select='text()[2]'/> ?

  And what produces the following (to be sure you get
an empty string, and not a string full of spaces):

    <xsl:value-of select="translate(text()[1], ' ', '_')"/> ?

> When I put the prefix "." return to me "Trying accessing
> only this" + "blablablablabla" + "blablablablabla", with
> your descedents.

  As said, it's the way 'xsl:value-of' works.  It uses all
text nodes descendants of "." (depending of the select
expression, indeed).  And CDATA are just text pieces.

> Is it necessary to use the node to separate the texts
> inside the node?

  I don't understand this sentence.  Can you explain a bit
further, please?

--drkm




















	

	
		
___________________________________________________________________________ 
Nouveau : tiliphonez moins cher avec Yahoo! Messenger ! Dicouvez les tarifs exceptionnels pour appeler la France et l'international.
Tilichargez sur http://fr.messenger.yahoo.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.