Sean Carolan wrote:
Thank you, this is helpful. Minidom is confusing, even the
documentation confirms this:
The name of the functions are perhaps misleading
But I'd start with the etree tutorial (of which
there are many variations on the web):
Ok, so I read through these tutorials
Peter Otten, 02.07.2012 09:57:
Sean Carolan wrote:
Thank you, this is helpful. Minidom is confusing, even the
documentation confirms this:
The name of the functions are perhaps misleading
Yes, I personally think that (Mini)DOM should be locked away from beginners
as far as possible.
Yes, I personally think that (Mini)DOM should be locked away from beginners
as far as possible.
Ok, I'm glad to hear that. I'll continue to work with ElementTree and
lxml and see where it takes me.
___
Tutor maillist - Tutor@python.org
To
I'm trying to parse some XML data (Book titles, ISBN numbers and
descriptions) with Python. Is there a *simple* way to import an XML
file into a dictionary, list, or other usable data structure? I've
poked around with minidom, elementtree, and untangle but am not
really understanding how they
On 01/07/12 21:49, Sean Carolan wrote:
... Is there a *simple* way to import an XML
file into a dictionary, list, or other usable data structure?
The simplest way using the standard library tools is (IMHO)
elementtree. minidom is a complex beast by comparison,
especially if you are not
The simplest way using the standard library tools is (IMHO)
elementtree. minidom is a complex beast by comparison,
especially if you are not intimately familiar with
your XML structure.
Thank you, this is helpful. Minidom is confusing, even the
documentation confirms this:
The name of the
Thank you, this is helpful. Minidom is confusing, even the
documentation confirms this:
The name of the functions are perhaps misleading
But I'd start with the etree tutorial (of which
there are many variations on the web):
Ok, so I read through these tutorials and am at least able to
On Mon, Jul 2, 2012 at 12:31 PM, Sean Carolan scaro...@gmail.com wrote:
How do you say, If the field is 11, then print the next value? The
raw XML looks like this:
datum
index1/index
field11/field
value9780470286975/value
/datum
Instead of iterating over the whole tree, grab all the