On May 16, 10:52 am, Stefan Behnel <stefan...@behnel.de> wrote: > Jake b, 16.05.2010 09:40: > > > Check out Amara:http://www.xml3k.org/Amara/QuickRef > > > It looks promising. For a pythonic solution over sax / dom. > > > >>> Iter(doc.team.player) > > # or > > >>> doc.team.player[0].name > > Ah, right, and there's also lxml.objectify: > > from lxml.objectify import parse > > root = parse('teamfile.xml').getroot() > > for player in root.player: > print(player.attrib) > > Prints an attribute dict for each player. > > Stefan
Thank you all so much!!! And it's not for a homework. Just trying to find out the style DOM, SAX, ElementTree etc. that fits better to my kind of thinking. Antonis -- http://mail.python.org/mailman/listinfo/python-list