|
Here is a preliminary patch for this interested in getting this fixed as quickly as possible.
I will commit it to CVS once I have finished testing it. Fixed in CVS.
Doesn't need to be fixed in 2.0 since we require PHP 5. Thanks Francois, I added it to http://docs.moodle.org/en/Moodle_1.9.5_release_notes#Known_problems_and_regressions
Francois,
thank you very much for quickly fixing this problem. I just installed html2text.php (Ver. 1.8.26.6 from MOODLE_19_STABLE) on our site and can confirm that now everything works as expected. Regards, Tested under 19_STABLE and verified the patch has fixed the problem. Thanks guys
The email bodies sent by forum_cron() is broken in Japanese environment.
The cause of this problem is utf8_encode() function in lib/html2text.php. refer from lib/html2text_readme.txt; ------ Modifications 1- fix for these warnings in cron: "html_entity_decode bug - cannot yet handle MBCS in html_entity_decode()!" by using this code: utf8_encode(html_entity_decode($string)); instead of: html_entity_decode($string, ENT_COMPAT, 'UTF-8'); -------- utf8_encode() function converts characters from ISO-8859-1 to UTF-8. function _convert() $text = trim(stripslashes($this->html)); // Convert <PRE> // Run our defined search-and-replace // Replace known html entities // Remove unknown/unhandled entities (this cannot be done in search-and-replace block) Or, use mb_convert_encoding() function, please. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
I can confirm that it is in fact broken on PHP4, however it works fine on PHP5.
Will look for a way to make this work on PHP4 too.
Cheers,
Francois