I feel stacked here trying to change encodings with Python 2.5
I have XML response, which I encode to UTF-8: response.encode(\'utf-8\'). That is fine, but t
response.encode(\'utf-8\')
Can you provide more details about what you are trying to do? In general, if you have a unicode string, you can use encode to convert it into string with appropriate encoding. Eg:
>>> a = u"\u00E1" >>> type(a) >>> a.encode('utf-8') '\xc3\xa1' >>> a.encode('latin-1') '\xe1'