XML.children() bug?


/ Published in: ActionScript 3
Save to your folder(s)



Copy this code and paste it in your HTML
  1. var xml1:XML =
  2. <foo>
  3. <bar>foobar</bar>
  4. </foo>;
  5. var xml2:XML =
  6. <foo>
  7. <bar>foobar</bar>
  8. <bar>barfoo</bar>
  9. </foo>;
  10. trace(xml1.children());
  11. /* returns
  12. foobar
  13. */
  14. trace(xml2.children());
  15. /* returns
  16. <bar>foobar</bar>
  17. <bar>barfoo</bar>
  18. */

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.