erp! I was close ;)

B.

On Fri, Feb 15, 2008 at 3:56 PM, Glen Pike <[EMAIL PROTECTED]>
wrote:

> You should be able to index children of the same type as array elements.
>
> root.accesscode.(@id == "S000").[0] or similar.
>
> Martin Tremblay wrote:
> > 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
> > Flashcoders@chattyfig.figleaf.com
> > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
> >
> >
> >
>
> --
>
> Glen Pike
> 01736 759321
> www.glenpike.co.uk <http://www.glenpike.co.uk>
> _______________________________________________
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to