Page 1 of 1

[solved] cms linker tinymce function menu bug

Posted: Wed Mar 03, 2010 12:51 pm
by samplist
In cmsms version 1.6.7 , 1.6.6 and probably previous versions too there is a small bug in the cms linker tinymce module.
In the menu, when page name is larger than 30 characters, it prints an � character at the end. This happens with utf-8 page names.

The solution to this is:

in file: modules/TinyMCE/TinyMCE.module.php replace following lines:

line 372 
$menutext=htmlspecialchars(substr($menutext,0,30),ENT_QUOTES)." …";
replace with:
$menutext=htmlspecialchars(mb_substr($menutext,0,30,'UTF-8'),ENT_QUOTES)." …";

line 409
$menutext=htmlspecialchars(mb_substr($menutext,0,30),ENT_QUOTES)." …";
replace with:
$menutext=htmlspecialchars(mb_substr($menutext,0,30,'UTF-8'),ENT_QUOTES)." …";

Hope this helps someone.

Is there any place that i can report such small bugs so that they can be fixed in next releases?

Thanks.