blob: ce2bb8ddf1f82e413a9eabc69cc7e0b30303f087 (
plain) (
blame)
1
2
3
4
5
|
For example, this works:
python -c 'from xml.etree import ElementTree; a=u"<body>\u1234</body>"; print type(a), a; b=ElementTree.XML(a.encode("unicode_escape")); print type(b.text), unicode(b.text).decode("unicode_escape");'
Ugly though :p. Ah well.
|