From owner-freebsd-questions@FreeBSD.ORG Mon Feb 21 23:00:59 2005 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9C06B16A4CE for ; Mon, 21 Feb 2005 23:00:59 +0000 (GMT) Received: from sage.thought.org (dsl231-043-140.sea1.dsl.speakeasy.net [216.231.43.140]) by mx1.FreeBSD.org (Postfix) with ESMTP id D9DAA43D55 for ; Mon, 21 Feb 2005 23:00:58 +0000 (GMT) (envelope-from kline@tao.thought.org) Received: from thought.org (tao [10.0.0.247]) by sage.thought.org (8.13.1/8.12.10) with ESMTP id j1LN0uex083984; Mon, 21 Feb 2005 15:00:57 -0800 (PST) (envelope-from kline@tao.thought.org) Received: from tao.thought.org (localhost [127.0.0.1]) by thought.org (8.12.11/8.12.11) with ESMTP id j1LN0t0P096830; Mon, 21 Feb 2005 15:00:55 -0800 (PST) (envelope-from kline@tao.thought.org) Received: (from kline@localhost) by tao.thought.org (8.12.11/8.12.11/Submit) id j1LN0tnM096797; Mon, 21 Feb 2005 15:00:55 -0800 (PST) (envelope-from kline) Date: Mon, 21 Feb 2005 15:00:54 -0800 From: Gary Kline To: Kent Stewart Message-ID: <20050221230054.GA58364@thought.org> References: <20050221065149.GA77396@thought.org> <200502202354.49454.kstewart@owt.com> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <200502202354.49454.kstewart@owt.com> X-Organization: Thought Unlimited. Public service Unix since 1986. X-Of_Interest: Observing 18 years of service to the Unix community User-Agent: Mutt/1.5.8i cc: Gary Kline cc: freebsd-questions@freebsd.org Subject: Re: how do i translate non-ascii chars??? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Feb 2005 23:00:59 -0000 On Sun, Feb 20, 2005 at 11:54:49PM -0800, Kent Stewart wrote: > On Sunday 20 February 2005 10:51 pm, Gary Kline wrote: > > l > > Guys, > > > > I've got sseveral HTML files with O-aigu and O-grave and > > others (these files were composed on a Mac. Rather than > > display as ['] (apostrophes) or backticks, they are rendered > > in full 8859-1. > > > > How to I translate these > 128 range characters? I'm > > wedged. > > When people do this, they are supposed to use the á, à, > and etc. Then, their browser does the correct display on their OS. > I didn't explain myself very well, sorry. Befow is a line from od -c on the index.html file. I'm not sure how this will be rendered in the different mailers, but in mutt with nvi, the "B" is surrounded by two iso8859-1 characters. In mozilla, same way. It is meant to be `B'. I've got over 28 files with what should be apostrophes and bcktcks rendered this way. putchar() outputs these characters in 8859 form --as characters. printf("0%o", ch); gives me their octal values. But trying to catch them with getchar() and it fails. gcc says that '\0325' is a dounle-wide. Maybe "od -c" is seeing this file as 16-bit characters... r h y m i n g Ô B Õ w o r d gary -- Gary Kline kline@thought.org www.thought.org Public service Unix