Author Topic: Can't convert message body when html meta tag charset name includes UNDERBAR(_)  (Read 3516 times)

Offline alping

  • Newbie
  • *
  • Posts: 2
First, thanks to support 'ks_c_5601-1987' charset. :)
(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)
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), and fails to render them.

To fix it, I think '[a-z0-9-]' will be replaced with '[a-z0-9-_]'.

Offline rosali

  • Hero Member
  • *****
  • Posts: 2,533
Please release a ticket @ trac.roundcube.net
Regards,
Rosali
__________________
MyRoundcube Project (commercial)

Offline alping

  • Newbie
  • *
  • Posts: 2
I released a ticket just now.

Offline jimmy1

  • Newbie
  • *
  • Posts: 2
    • http://www.janitorialservicefinders.com
i just saw your ticket. its nice.