Chinese characters broken after upgrading 1.1.6
all characters are broke after upgraded to 1.1.6 version, I am not able to read and write any Chinese words. Any clue on that? pls help !!!!
This discussion has been closed.
all characters are broke after upgraded to 1.1.6 version, I am not able to read and write any Chinese words. Any clue on that? pls help !!!!
Comments
Hi,
In 1.1.6, the character set for the database is set to UTF8 whenever Sendy connects to the database.
Can you check your database directly via phpmyadmin to see how the chinese characters are displayed?
Thanks.
Ben
i have the same problem. after upgraded to 1.1.6, all chinese characters are broken. please help
Hi @edwong,
In 1.1.6, the character set for the database is set to UTF8 whenever Sendy connects to the database.
Can you check your database directly via phpmyadmin to see how the chinese characters are displayed?
Thanks.
Ben
no phpmyadmin. but in 1.1.5, it's working fine. so should be coding problem.
any chance you can send us the 1.1.5 version? we need to fix this problem soon. thx (i emailed you about 30 mins ago)
Hi @edwong @hkocer
I investigated this further and realized chinese characters uses utf16. Sendy sets the character set to utf8 by default in 1.1.6.
I've added a fix in 1.1.6 so that you can set the character set to utf16 to display chinese characters. Please re-download Sendy at http://sendy.co/get-updated and re-upgrade your current installation.
Then include the following line in your /includes/config.php file right after
define('COOKIE_DOMAIN', '');
$charset = 'utf16';
Sendy will use utf16 which will in turn write and retrieve chinese characters correctly from the database.
Thanks.
Ben
great. thx ben. all pages works now, except the previous email subject line (in report page and campaign page) is still wrong. user name and email subject in campaign detail page works fine.
figured out why. in the code, just htmlentities($row['title'],ENT_QUOTES,"UTF-8")
(do not just use htmlentities($row['title'])
Thanks @edwong, I've updated the build with ENT_QUOTES flag for the htmlentities method.