<<< Date Index >>>     <<< Thread Index >>>

Re: Strange Characters In Emails



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Wednesday, October  1 at 09:18 PM, quoth Chris G:
>On Wed, Oct 01, 2008 at 08:03:15PM +0100, Chris Willard wrote:
>> Hello All,
>> 
>> I am receving emails that have strange characters in them! Some
>> examples are as follows.
>> 
>> \240 - instead of a space
>> \243 - instead of a pound sign
>> 
>> Do I need to process the emails before they get to mutt?
>> 
> It's most likely because the sender isn't setting the character set 
> correctly in the headers.  In particular \243 only means a pound 
> sign if you have set the character set correctly, it can mean 
> different things in different character sets.

Specifically, \243 means a pound sign in ISO-8859-1 (aka Latin-1), 
ISO-8859-15, MACINTOSH and Windows-1252 character sets. \240 means a 
space in ISO-8859-1 (aka Latin-1), ISO-8859-15, and Windows-1252 
character sets.

If mutt isn't displaying them correctly, it's, as Chris G said, 
probably because the sender didn't label the character set correctly.  
The most common error is that things are sent in Windows-1252 and 
simply not labeled at all, and pretending that they're Windows-1252 is 
something you can tell mutt to do that's completely harmless. 
Unfortunately, not all errors can be fixed, but these probably 
(usually) can. Here's the best set of hooks for Western languages... 
add them to your muttrc (credit to Alain Bench):

     charset-hook ^unknown-8bit$ windows-1252
     charset-hook ^x-user-defined$ windows-1252
     charset-hook ^iso-8859-1$ windows-1252
     charset-hook ^us-ascii$ windows-1252
     charset-hook ^none$ windows-1252
     charset-hook ^iso-8859-8-i$ iso-8859-8
     charset-hook ^gb2312$ gb18030

~Kyle
- -- 
Men, as an organization, are getting more women than any other group 
working anywhere in the world. Wherever women are, we have men looking 
into it.
                                                      -- Jerry Seinfeld
-----BEGIN PGP SIGNATURE-----
Comment: Thank you for using encryption!

iEYEARECAAYFAkjj9McACgkQBkIOoMqOI16GvQCfcBR8VyL4TffRysuRH2LCbfWU
7JIAnRt9LAL779mK4UoOdzCly5wuQ/As
=+yHh
-----END PGP SIGNATURE-----