import libxml2 input = libxml2.inputBuffer(open("ex2.xml")) reader = input.newTextReader("ex2.xml") ret = reader.Read() while ret == 1: print reader.Name() ret = reader.Read()
See example 2, XML
Daniel Veillard
7 of 20