I have some arabic characters in the tiny mce. In the editor they get displayed properly, but after save there are only questionsmarks. How to get it right?
Is this a problem with TinyMCE or your database?
Test by disabling TinyMCE - same problem, right?
http://bobsguides.com/convert-db-utf8.html
https://forums.modx.com/thread/?thread=22960&i=1&page=2
TinymceWrapper: Complete back/frontend content solution.
Harden your MODX site by
passwording your three main folders:
core, manager, connectors and renaming your
assets (thank me later!)
5 ways to sniff / hack your own sites; even with renamed/hidden folders, burst them all up, to see how secure you are not.
Damn it. Your' right. My database is latin1_swedish_ci.
How can I assure or test that a db conversion will fix it?
When you try it and it works, then you will be sure.
1. Backup your database
2. Place all your natural faith in BobRay
3. Have confidence because I did it successfully for Chinese
3. Read the instructions carefully and do the deed
4. Prepare for the worst, but don't swear when it happens!
5. Prepare for intense joy when success comes
[ed. note: donshakespeare last edited this post 10 years, 7 months ago.]
TinymceWrapper: Complete back/frontend content solution.
Harden your MODX site by
passwording your three main folders:
core, manager, connectors and renaming your
assets (thank me later!)
5 ways to sniff / hack your own sites; even with renamed/hidden folders, burst them all up, to see how secure you are not.
As donshakespeare says, there's a conversion script and the process to use it here:
http://bobsguides.com/convert-db-utf8.html.
To my knowledge, it has not been tested with the current version of MODX, so back things up and let us know if it works or not.
[ed. note: BobRay last edited this post 10 years, 7 months ago.]
-
☆ A M B ☆
- 24,524 Posts
I just used it (with some fiddling with the output) to convert to utf8mb4, so it seems to still be working fine.
It is not the newest modx installation. I will give it a try and return.
Quote from: sottwell at Feb 06, 2016, 08:24 PMI just used it (with some fiddling with the output) to convert to utf8mb4, so it seems to still be working fine.
Good to hear, thanks.
-
☆ A M B ☆
- 24,524 Posts
For the utf8mb4 conversion, I edited the output in a text editor, replacing all the "varchar(255)" with "varchar(248)", thus making those fields small enough to fit in the 1000-char limit for indexes, while not really hurting the use of the fields.
Of course, if somebody is using the full 255 characters of the original varchar setting, they'll lose the last 8 characters. So it's not a really great solution. But if one wants to use one of the languages that requires the full 4-byte range of standard utf8, it's about the only option.
Really, only the fields used for the indexes need to be shorter, but that's something that has to be dealt with in the schemas themselves.