W3C home > Mailing lists > Public > html-tidy@w3.org > July to September 2005

Re: Chinese characters in BBEdit?

From: Bjoern Hoehrmann <derhoermi@gmx.net>
Date: Mon, 01 Aug 2005 10:41:49 +0200
To: Chris von Rosenvinge <chris@vingdesign.com>
Cc: html-tidy@w3.org
Message-ID: <42f4dfc9.363555000@smtp.bjoern.hoehrmann.de>

* Chris von Rosenvinge wrote:
>I use the BBTidy plug-in (1.0b10-01 Dec 02, © W3C 
>1998-2002, Terry Teague 1998-2004) in BBEdit 
>8.2.2, and it has a bug that renders the tidied 
>file in Chinese characters. As a workaround, I 
>save the document in UTF-16 coding. At this point 
>I can reopen the document and it reads normally 
>in BBEdit, but the Chinese characters show up in 
>a browser. I then zap non-ASCII characters and 
>resave the file in Latin 1 coding. It finally 
>reads normally both in BBEdit and in a browser.

The best way to deal with this is probably to do everything in UTF-8 and
properly declare the encoding. Tidy has a -utf8 switch to say that the
input is in utf-8 and that utf-8 should be used for the output, BBEdit
probably has a setting to say that the document is utf-8 encoded and you
need to add a <meta http-equiv=Content-Type content="text/html;charset=
utf-8"> to the <head> of the document. This should just work then, no
matter which characters you use in the document.
Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de
Weinh. Str. 22 · Telefon: +49(0)621/4309674 · http://www.bjoernsworld.de
68309 Mannheim · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/ 
Received on Monday, 1 August 2005 08:41:59 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:38:55 UTC