Grabbing CData values with Xpath can be tricky, but I have found a way
that works, like this for example:

XMLNode((XPath.selectNodes(myXML, "content/
introduction/text()")[0])).nodeValue

Basically, you use XPath to grab the 0 element in the array it creates,
and then Flash's XML object to grab the node value 

Jason Merrill   |   E-Learning Solutions   |  icfconsulting.com










>>-----Original Message-----
>>From: [EMAIL PROTECTED] [mailto:flashcoders-
>>[EMAIL PROTECTED] On Behalf Of Ryan Luce
>>Sent: Thursday, February 02, 2006 10:57 AM
>>To: Flashcoders mailing list
>>Subject: Re: [Flashcoders] dynamic html text with xpath and cdata
>>
>>Oops, that was a spelling error, i do have the < in the cdata field...
and
>>it is an html textfield. I may just skip xpath and use flash's normal
xml
>>functions... will try when i get home.
>>Thanks,
>>Ryan.
>>
>>On 2/1/06, Troy Rollins <[EMAIL PROTECTED]> wrote:
>>>
>>>
>>> On Feb 1, 2006, at 11:19 PM, Ryan Luce wrote:
>>>
>>> > For some reason when i load cdata text in using xpath  like this
>>> > thexml.selectNodes("//node/subnode/text()") where there is a br it
>>> > breaks
>>> > the line, but leaves the br in the text... anyone know why this is
>>> > happening? Also my textfield will not align to the right, i have
>>> > manually
>>> > set it to align to the right, and i have made a textformat to
align
>>> > it to
>>> > the right to no avail. The text box is manually drawn onto stage.
>>>
>>> Dumb question... the field is set to HTML text, right?
>>>
>>> --
>>> Troy
>>> RPSystems, Ltd.
>>> http://www.rpsystems.net
>>>
>>>
>>> _______________________________________________
>>> Flashcoders mailing list
>>> Flashcoders@chattyfig.figleaf.com
>>> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>>>
>>_______________________________________________
>>Flashcoders mailing list
>>Flashcoders@chattyfig.figleaf.com
>>http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
NOTICE:
This message is for the designated recipient only and may contain privileged or 
confidential information. If you have received it in error, please notify the 
sender immediately and delete the original. Any other use of this e-mail by you 
is prohibited.
_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to