xml file :
<global> <rtmp> <fcsapp> <password> <key>hello123</key> <key>check123</key> </password> </fcsapp> </rtmp> </global> python code : To obtain all the key tag values. hello123 check123
using xml.etree.ElementTree for streams in xmlRoot.iter('global'): xpath = "/rtmp/fcsapp/password" tag = "key" for child in streams.findall(xpath): resultlist.append(child.find(tag).text) print resultlist The output obtained is [hello123], but I want it to display both ([hello123, check123])
How do I obtain this?
{}button), not quoting... (Then you don't have to mangle your XML).