Skip to Content.
Sympa Menu

devel - Re: [sympa-dev] encode_mimewords and charsets

Subject: Developers of Sympa

List archive

Chronological Thread  
  • From: Olivier Salaün - CRU <address@concealed>
  • To: Roman Barczyński <address@concealed>
  • Cc: address@concealed
  • Subject: Re: [sympa-dev] encode_mimewords and charsets
  • Date: Fri, 07 Jan 2005 09:23:43 +0100

Roman Barczyński wrote:
Hi, did you ever considered making encode_mimewords charset configurable?

e.g. on per-list basis in excl/*/config
default_charset ISO-8859-2

And modify code
- $msg_header->replace('Subject',MIME::Words::encode_mimewords($msg_header->get('Subject')));
+ $msg_header->replace('Subject',MIME::Words::encode_mimewords($msg_header->get('Subject'),'Q',__THAT_CHARSET__));
  
In most places in the code we specify the encoding to be used ; we'll add missing ones before releasing Sympa 5.
The encoding used is the one associated with the language set for the list.

For example if you set your list language as follows :
lang   hu
Then message header fields for this list will be encoded with the charset defined in hu.po header, ie iso-8859-2
Another (best in my oppinion) way would be encode strings same charset as it was before decoding.
  
I agree but we did not find an easy way to do it this way, mainly because MIME-tools does not provide appropriate functions and also because one header field may contain mix strings encoded with different encodings.  But we'll try to make things better in the near future.
I've meet problem because most of my messages I send using ISO-8859-2.
After sympa handles those mesages Subject becomes ISO-8859-1 quoted_printable-encoded.

Also could you help me providing __THAT_CHARSET__ replacement in code above to hot-fix my sympa installation? __THAT_CHARSET__ shoud be replaced with encoding taken eigter from original subject charset or from default_charset from list config file...
  
You should no more have this problem with Sympa 5.0b if your list language is set to a language that uses ISO-8859-2. 

-- 
Olivier Salaün
Comité Réseau des Universités
-------------------------------------------
Validation signature / Trusting  signature: --> http://igc.cru.fr/trust.html
------------------------------------------- 

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature




Archive powered by MHonArc 2.6.19+.

Top of Page