PDA

View Full Version : browsing xml



danny0085
August 4th, 2008, 12:41 PM
I have an XML file:

<espanol>
<cat_hos> Hospedaje </cat_hos>
<cat_ali> Alimentaci\$oacento;n </cat_ali>
</espanol>

I need to access every node and make operations

for each(var nodo:XML in myXML.elements())
{
nodo_nombre = String(nodo.name());
trace(nodo_nombre); // cat_hos
trace(myXML.nodo_nombre); // null --> what is the error?
}

Felixz
August 4th, 2008, 07:40 PM
myXML.child(nodo_nombre)

malik
August 5th, 2008, 05:11 AM
wouldnt it be a lot easier if you just followed the clean cut way. using an XMLList?