Hi all.
I faced some problem with OTRS 1.2. When we send message to customer using koi8-r encoding, his(her) mail client doesn't display mail header(-s) properly: any linear-white-space characters are ignored (not displayed).
As I understand header(-s) is(are) encoded using encode_mimewords() function from package MIME::Words in source file Kernel/System/Ticket/SendArticle.pm. Here:
...
# --
# build mail ...
# --
# do some encode
foreach (qw(From To Cc Bcc Subject)) {
if ($Param{$_}) {
$Param{$_} = encode_mimewords($Param{$_}, Charset => $Charset) || '';
}
} ...
After encode_mimewords() we have Subject string like this:
[Ticket#: 2004082310000032] Re: =?KOI8-R?Q?=F0=D2=CF=D7=C5=D2=CB=C1?= =?KOI8-R?Q?=CB=CF=C4=C9=D2=CF=D7=CB=C9?=
So every russian word is encoded with =?KOI8-R?Q? "braces". But when mail clien displays this header, it "deletes" any spaces between words.
Here is the quote from RFC-1522 (http://www.faqs.org/rfcs/rfc1522.html):
"When displaying a particular header field that contains multiple
encoded-words, any linear-white-space that separates a pair of
adjacent encoded-words is ignored. (This is to allow the use of
multiple encoded-words to represent long strings of unencoded text,
without having to separate encoded-words where spaces occur in the
unencoded text.)"
In description of MIME-tools library (http://search.cpan.org/dist/MIME- tools/lib/MIME/Words.pm#DESCRIPTION): "Warning: this is a quick-and-dirty solution, intended for character sets which overlap ASCII. It does not comply with the RFC-1522 rules regarding the use of encoded words in message headers. You may want to roll your own variant, using encoded_mimeword(), for your application. Thanks to Jan Kasprzak for reminding me about this problem."
So using encode_mimewords() function may cause some problems, doesn't it?
Does anybody know how to solve this problem? Tnanx in advance.
-- Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/ _______________________________________________ OTRS mailing list: dev - Webpage: http://otrs.org/ Archive: http://lists.otrs.org/pipermail/dev To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/dev
