libxml2 - Attribute
Richard Mertens
richard.mertens at wolfi.org
Fri Jul 11 04:00:15 EDT 2003
More information about the Python-list mailing list
Fri Jul 11 04:00:15 EDT 2003
- Previous message (by thread): text file edit object
- Next message (by thread): Embedding Python, threading and scalability
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
I'd like to read the attributes from a node in my xml - file, but i didn't
found an example for this. Could someone help me please?
I ghet the attribute count work neither.
example - xml file
<test>
<muh attr1="test1" attr2="test">kulimuh</muh>
</test>
example python - script
ctxt = doc.xpathNewContext()
res = ctxt.xpathEval("//test/muh")
for myres in res:
print myres.AttributeCount
File "/usr/lib/python2.2/site-packages/libxml2.py", line 189, in __getattr__
raise AttributeError,attr
AttributeError: AttributeCount
- Previous message (by thread): text file edit object
- Next message (by thread): Embedding Python, threading and scalability
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list