I have following dictionary structure
[{
"Body" : [{
"Universal Lift Support" : ["1\"-9\" Extended Length",
"10\"-14.5\" Extended Length",
"15\"-19\" Extended Length",
"20\" + Extended Length"]
}]
I wanted to use the dicttoxml
library to get desired xml-output like:
<root>
<Body>
<Universal Lift Support>
1"-9" Extended Length
10"-14.5" Extended Length
15"-19" Extended Length
20" + Extended Length
</Universal Lift Support>
However, after applying the next code:
dicttoxml.dicttoxml(result, attr_type=False, root=True)
I got xml-structure like:
<?xml version="1.0" encoding="UTF-8" ?><root><item><Body><item><Universal_Lift_Support><item>1"-9" Extended Length</item><item>10"-14.5" Extended Length</item><item>15"-19" Extended Length</item><item>
What options can help to format and get the output as descibed above?