On 14 May 2005 02:23:55 -0700, "Dan Bishop" <[EMAIL PROTECTED]> wrote:
>Svennglenn wrote:
>> I'm having problems replacing text in a
>> unicode string.
>> Here's the code:
>>
>> # -*- coding: cp1252 -*-
>>
>> titel = unicode("ä", "iso-8859-1")
To the OP:
This is not causing the later problem, but
Svennglenn wrote:
> I'm having problems replacing text in a
> unicode string.
> Here's the code:
>
> # -*- coding: cp1252 -*-
>
> titel = unicode("ä", "iso-8859-1")
> print titel
> print type(titel)
>
> titel.replace("ä", "a")
>
> When i run this program I get this error:
>
> titel.replace("ä",
I'm having problems replacing text in a
unicode string.
Here's the code:
# -*- coding: cp1252 -*-
titel = unicode("ä", "iso-8859-1")
print titel
print type(titel)
titel.replace("ä", "a")
When i run this program I get this error:
titel.replace("ä", "a")
UnicodeDecodeError: 'ascii' codec ca