Failed to display HTML document in ISO-8859-1 encoding

Hi Milos,

It looks like you're trying to send non ISO-8859-1 characters to your HTML
control, which is trying to convert it. Either you can strip out any
offending characters, or else you probably need to change your html header.

If you make sure that when you set the contents of your HTML window to
include an html header which contains:

<head>
....
<meta http-equiv="Content-Type" content="text/html; charset=XXXXXXXXX">
<title>...</title>
</head>

with your charset modified to a suitable encoding, it should work. At least,
that's how I got it to work on my system.

Hope that helps,
Ant

···

On Mon, 4 Sep 2006 01:40:17 +0100, Milos Negovanovic wrote:

Hi all,

I am getting this error with wx.html.HtmlWindow. Is there any
workaround to this? I am using 2.6.3.3 on NetBSD.

Regards
Milos

--------------------------------------------------------------------
- To unsubscribe, e-mail: wxPython-users-
unsubscribe@lists.wxwidgets.org For additional commands, e-mail:
wxPython-users-help@lists.wxwidgets.org

Milos Negovanovic wrote:

···

On Mon, Sep 04, 2006 at 05:38:30PM +0200, Gabriele wrote:

If html is a unicode iso-8859-1 string, you have 2 possibilities:
1) set the system default encoding to iso-8859-1
2) decode your string to ascii: html.decode('iso-8859-1')

I hope that will help you.

Still i get that annoying pop-up with the same error.

One thing ... I didn't realise that stock wxPython in NetBSD package
system is ANSI version. Would this make any difference?

Yes, it probably would. In a unicode build the HtmlWindow will use unicode internally and will have an easier time representing the various encodings.

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!