EX4 cannot find a node using E4X when one of it's sibling has the same
name.

Is there a way to avoid this problem ?


var xmlData:XML = 
<root>
         
         <accesscode id="S001">
           <shortcut>S001</shortcut>
           <shortcut>smallbusiness</shortcut>
     </accesscode>
         
     <accesscode id="S000">
           <shortcut>S000</shortcut>
           <shortcut2>S000</shortcut2>
     </accesscode>

</root>;


trace(xmlData.accesscode.(@id == "S000"));
trace("-------------");
trace(xmlData.accesscode.(shortcut == "S000"));
trace("-------------");

trace(xmlData.accesscode.(@id == "S001"));
trace("-------------");
trace(xmlData.accesscode.(shortcut == "S001"));
trace("-------------");

Martin T.
LVL



_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to