I have a string variable contents
with following value:
<ph type="0" x="1"></ph>
I try to write it to a XML element as follows:
elemen_ref.text = contents
After I write XML tree to a file and check it with Notepad++, I see following value written to the XML element:
<ph type="0" x="1"></ph>
How do I write unescaped string? Please note that this value is copied from another XML element which remains intact after writing tree to a file, so the issue is with assigning value to a text
attribute.