📜  python 将 dict 转换为 xml - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:37.642000             🧑  作者: Mango

代码示例1
from dicttoxml import dicttoxml

array = [
    {
        'time': {"hour":"1", "minute":"30","seconds": "40"}
    },
    {
        'place': {"street":"40 something", "zip": "00000"}
    }
]

xml = dicttoxml(array, custom_root='test', attr_type=False)