  | |  | Writing to CDATA nodes... | Writing to CDATA nodes...
2004-02-19 - By Isaac Rivera
Back The XML parser in Flash can read cdata nodes which is great. But flash doesn 't really have a CDATA node type which is a pain.
If I read an xml: <string > <![CDATA[ <p >Some styled text here. </p >] > </string >
I can correctly get the value of the <string > node as " <p >Some styled text here. </p > ". Great.
Now if I modify the string to say: " <p >Some other styled text here. </p > " and write it back to the node <string >, the CDATA wrapper is gone.
If I try and add it manually: " <![CDATA[ " + " <p >Some other styled text here. </p > " + "]] > ", then it gets escaped. unescaping it doesn 't do the trick.
The problem is that it becomes part of the string and not a wrapper anymore.
Any suggestions?
Isaac Rivera
=-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- --
Supported by Fig Leaf Software
=-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- --
Be sure to check the archives and the wiki:
http://chattyfig.figleaf.com/
=-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- --
http://chattyfig.figleaf.com/cgi-bin/ezmlm-cgi?1:mss:104736
=-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- --
To unsubscribe send a blank e-mail to:
Normal Mode: flashcoders-unsubscribe@(protected)
Digest Mode: flashcoders-digest-unsubscrive@(protected)
|
|
 |