Roundcube Community Forum

SVN Releases => Issues & Bugs => Topic started by: alping on August 20, 2008, 03:01:37 PM

Title: Can't convert message body when html meta tag charset name includes UNDERBAR(_)
Post by: alping on August 20, 2008, 03:01:37 PM
First, thanks to support 'ks_c_5601-1987' charset (http://trac.roundcube.net/ticket/1484380). :)
(ks_c_5601-1987 charset is used in IE, Outlook, Outlook Express, etc.. in Korean Version)

But, in Roundcube 0.2 alpha-1, roundcube fails to render message body that encoded by ks_c_5601_1987 charset.

Because Regular Expression used by 'rcmail_print_body function' for charset name is '[a-z0-9-]'. (See 'program/steps/mail/func.inc file 539, 540 line (http://trac.roundcube.net/browser/tags/roundcubemail/v0.2-alpha/program/steps/mail/func.inc))
So RoundCube can't find 'ks_c_5601-1987 charset', and can't replace it to 'RCMAIL_CHARSET'(in my case, UTF-8 ).
Instead of 'UTF-8', RoundCube changes meta tag charset name to 'UTF-8_c_5601-1987'. This is Wrong Charset. DOMDocument Object can't understand it(this is used in washhtml (http://trac.roundcube.net/browser/tags/roundcubemail/v0.2-alpha/program/lib/washtml.php)), and fails to render them.

To fix it, I think '[a-z0-9-]' will be replaced with '[a-z0-9-_]'.
Title: Can't convert message body when html meta tag charset name includes UNDERBAR(_)
Post by: rosali on August 20, 2008, 03:20:02 PM
Please release a ticket @ trac.roundcube.net
Title: Can't convert message body when html meta tag charset name includes UNDERBAR(_)
Post by: alping on August 20, 2008, 03:58:03 PM
I released a ticket (http://trac.roundcube.net/ticket/1485287) just now.
Title: Can't convert message body when html meta tag charset name includes UNDERBAR(_)
Post by: jimmy1 on July 21, 2011, 01:21:23 PM
i just saw your ticket. its nice.