XML CDATA issue

Hi all,

I’m having an issue with Flash/AS3 where my CDATA is not being recognized by the xml parser in situations where the cdata is located in an element that has one or more nodes.

for example, I can see all of the text within the CDATA block when I set a textArea’s htmlText to myXML.sentence

(myXml)


<text>
<sentence>
<![CDATA[ Here is a bunch of text. And here is a little more: <, >, &, " and ' with no problem. Expecting a third line? Neither was I!]]>
</sentence>
</text>

however, when I add a node or two within the , element, the compiler doesn’t read the the CDATA at all.


<text>
<sentence>
<someNode>This is the only thing that will show up now.</someNode>
<![CDATA[ Here is a bunch of text. And here is a little more: <, >, &, " and ' with no problem. Expecting a third line? Neither was I!]]>
</sentence>
</text>

Can anyone explain what is going on here and/or how I can solve this issue?

Thanks in advance,

mightyRGB