lack of knowledge of .nodeValue's use = 5 hours of my life.
Much Thanks! Mark Winterhalder wrote:
i'm guessing that... trace( typeof _root.country ); // XMLNode trace( _root.country.nodeValue ); // US trace( _root.country.nodeValue == "US" ); // true am i right? hth, mark On 2/5/06, dls <[EMAIL PROTECTED]> wrote:I am bringing data in from XML, and assigning it a variable name in flash _root.country = myXML.firstChild.childNodes[4].childNodes[3].childNodes[0]; so far so good, I know it has loaded and when I view my variables _root.country shows as US. In my code I am trying to do the following comparison: if(_root.country == "US"){ //do something }; Doesn't work. Aren't they both strings? When I test _root.country = "US"; if(_root.country =="US"){ //do something }; it works fine. Is there a way to insert quote marks around the variable from the XML? Why isn't it working? Any help would be appreciated! --dan _______________________________________________ Flashcoders mailing list [email protected] http://chattyfig.figleaf.com/mailman/listinfo/flashcoders-- http://snafoo.org/ jabber: [EMAIL PROTECTED] _______________________________________________ Flashcoders mailing list [email protected] http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
_______________________________________________ Flashcoders mailing list [email protected] http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

