views:

46

answers:

1

Can I filter 2 different node types in E4X same as attributes but then on node type? I cannot find this anywhere:

Something like":

$.book_xml.pages.page.(node == 'front' && node =='back');


<pages>
 <page>
  <front></front>
  <back></back>
 </page>
<pages>
A: 

Not familiar with e4x in javascript but this works in actionscript:

trace(book_xml.pages.page.*.(localName()=="front" || localName()=="back"));

Returns both the front and back nodes.

invertedSpear
Oh thx I was looking for actionscript :D
Chris