dom = minidom.parseString(xml_text)
params = dom.getElementsByTagName('Parameter')
for param in params:
    name = param.getAttribute('name')
if name in data:
    for item in param.getElementsByTagName('*'):
        item.firstChild.replaceWholeText(data[name])
print(dom.toxml())
open('output.xml', 'wb').write(dom.toxml())
Editing the XML texts from a XML file using Python