from xml.dom import minidom xmldoc = minidom.parse('binary.xml') reflist = xmldoc.getElementsByTagName('ref') reflist print reflist[0].toxml()
Name (required)
email (will not be published) (required)
Website