Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
  • baijianpeng Friend

    I made a testing website with JA University template the latest version. I use the JA Side News Module in this template to show a news module at "sidebar-2" position. You can see it at:

    The module title is "微想精彩".

    You can see that when truncating the description text, there is two un-readable strnage symbols (like ? but not really a question mark) at the point of cutting off text.

    Why this happened?

    It seems that this module can not handle Chinese characers properly.

    Could you please improve it to support Chinese language ?

    Thank you.

    1. ja-sidenews-module-truncate-chinese-characters
    Saguaros Moderator


    What is the database collation of your site? For languages with special characters like yours, the database collation should be utf8

    baijianpeng Friend

    Following is the "system infomation" from my Joomla backend:

    Database Version 5.6.31-77.0
    Database Collation latin1_swedish_ci
    Database Connection Collation utf8mb4_general_ci
    PHP Version 7.0.8
    Web Server Apache
    WebServer to PHP Interface apache2handler
    Joomla! Version Joomla! 3.6.2 Stable [ Noether ] 4-August-2016 23:41 GMT
    Joomla! Platform Version Joomla Platform 13.1.0 Stable [ Curiosity ] 24-Apr-2013 00:00 GMT

    Did you used mb_substr() instead of substr() for that truncating feature?

    Thank you.

    Saguaros Moderator

    Did you get it solved? I see the title is fine now.

    baijianpeng Friend

    Yes, I did a replacement: replace ALL "substr" with "mb_substr" in all files (not only php files, but all files) of that module, now it can truncate Chinese characters properly.

    I hope you improve your module with this same method. Otherwise, next time I upgrade this module the problem will come back again.

    Saguaros Moderator

    I lined it up in our bug tracking system and it will be updated in upcoming version:

    Thank you for your report! It’s much appreciated.

Viewing 6 posts - 1 through 6 (of 6 total)

This topic contains 5 replies, has 2 voices, and was last updated by  Saguaros 2 years, 10 months ago.

We moved to new unified forum. Please post all new support queries in our New Forum