MX2004: XPathAPI CDATA selectSingleNode and HTML formatting


my subject is pretty much my problem, i am using MX2004’s XPathApi ‘selectSingleNode’ which is working nicely, i have done a wee bit of fiddling;

_root.selectedText = "About Us "
centreMe.textContent.htmlText = mx.xpath.XPathAPI.selectSingleNode(this.firstChild, "/data/item[@name = '"+ _root.selectedText + "']/*");

I would like to be able to change the content depending on what the variable is, and this seems to work fine. The content should be formatted text (with

etc…), so i am using CDATA tags to make sure no confusion is made with <>'s (and if i dont it only pulls in a small section - as expected).

Only problem is that for some reason it forgets it is a html formatted bit of CDATA and spits out the

tags with the rest of the content… i have placed in “centreMe.textContent.html = true;” make sure it knows its html but it really doesnt want to know.

I tried using selectNodeList to an array and printing this - which works, without CDATA tags, but adds a really annoying “,” at the end of each “array item” it is printing.

Any help would be fantastic as i have also been through an entire saga to get here trying different techniques to get html tags displaying correctly within CDATA - and i guess this is ultimately my problem?

Thanks for your time!

edit > now i am having a really “noobie” problem (if my one above wasnt already enough)

this works;

bla.html = true;
bla.htmlText = "this is frustrating?";

but this doesnt display anything in my dynamic textbox;

bla.html = true;
bla.htmlText = "<b> this is frustrating?</b>";

why does actionscript hate me? its player 7 with as2 :expressionless: