Flash doesn't actuall support the CDATA tag. It sort
of does, but all <'s and >'s get replaced with <'s
and >'s.
When you stick it in a text field, it correctly
interprets the HTML entities, which leads to you
getting HTML tags where they shouldn't be.
--- "Chris W. Paterson" <[EMAIL PROTECTED]> wrote:
> here is the snipit of code:
>
>
local.obCredits[this.firstChild.childNodes[i].firstChild.childNodes[j].nodeName]
> =
>
this.firstChild.childNodes[i].firstChild.childNodes[j].childNodes;
>
> local.obCredits --- This is passed as an object
> later to a Class.
>
>
[this.firstChild.childNodes[i].firstChild.childNodes[j].nodeName]
> --- this loops the node names
> and places them as properties of the local.obCredits
> object, one of them being the "content"
>
>
this.firstChild.childNodes[i].firstChild.childNodes[j].childNodes;---
> this is how I am trying to
> access the content of that node.
>
> First off, I'm guessing I should use .nodeValue?
> Will that give me the entire node with
> "<![CDATA[]]>"? Is it even possible to read the
> html value for html text?
>
> Thanks so much!
> -Chris
>
> --- Danny Kodicek <[EMAIL PROTECTED]> wrote:
>
> > > XML:
> > > <content><![CDATA[Blah blah <a
> > > href="somelink.com">someLink</a> <b> some bold
> text </b>]]></content>
> > >
> > > The problem is the XML Node is not reading as a
> string and
> > > the html text field reads the node as a literal
> string
> > > instead of html text. I mean it prints something
> like "Blah
> > > blah <a href="somelink.com">someLink</a> <b>
> some bold text
> > > </b>" in my text field.
> > >
> > > AS:
> > > var tt:TextField =
> > >
>
m.createTextField("txt",m.getNextHighestDepth(),0,0,0,0);
> > > tt.autoSize = true;
> > > tt.selectable = false;
> > > tt.embedFonts = true;
> > > tt.antiAliasType = "advanced";
> > > tt.html = true;
> > > tt.htmlText = local.ob.content; // myXml value
> >
> > How are you getting this local.ob.content? That's
> the key issue, really.
> > Have you tried a trace() of this value?
> >
> > My guess is that you're including the [CDATA bit
> of the field, which means
> > you're telling the field to render the text
> literally, which is exactly what
> > it's doing.
> >
> > Danny
> >
> > _______________________________________________
> > [email protected]
> > To change your subscription options or search the
> archive:
> >
>
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
> >
> > Brought to you by Fig Leaf Software
> > Premier Authorized Adobe Consulting and Training
> > http://www.figleaf.com
> > http://training.figleaf.com
> >
>
>
>
>
>
>
>
>
>
____________________________________________________________________________________
> Looking for a deal? Find great prices on flights and
> hotels with Yahoo! FareChase.
> http://farechase.yahoo.com/
> _______________________________________________
> [email protected]
> To change your subscription options or search the
> archive:
>
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
> Brought to you by Fig Leaf Software
> Premier Authorized Adobe Consulting and Training
> http://www.figleaf.com
> http://training.figleaf.com
>
____________________________________________________________________________________
Be a better Heartthrob. Get better relationship answers from someone who knows.
Yahoo! Answers - Check it out.
http://answers.yahoo.com/dir/?link=list&sid=396545433
_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com