Emoticons in Rich text editor

Does anyone know which Rich Text Editor to use which will support Emoticons?
I have some customer reviews from social media where people have used Smileys etc - which would be nice ont he website, but I’ve tried several Rich Text Editor (TinyMCE, TinyMCEWrapper, and TinyMCE Rich Text Editor) but all of them render the emoticons as question marks.

or do I need to do something in the background to enable this?

It’s within a migx TV, and when I open it, the emtocions are still there in the editor, but just don’t render on the page.


Maybe it’s a problem with the character set that you use for your database.
Make sure you use “utf8mb4” as your database/table charset.

Hmm change the collation of th database tables, but it’st still rendering as question marks. Also, if I re-open the migx TV, it’s already changed it to question marks, so maybe it’s not the rendering, but the saving of the TV in migx?

It’s unclear to me, where you enter the emoticons and when and where they then show up as question marks.

  • If it’s old data that was stored to the database before the charset was changed to “utf8mb4”, then those emoticons won’t reappear.
  • It shouldn’t matter whether you use a MIGX TV or another TV or just place the emoticon in the content.
  • If you check the data in the database (e.g. with phpMyAdmin | table = modx_site_tmplvar_contentvalues) can you see the emoticons there? Can you enter emoticons directly with phpMyAdmin into the database?

Sorry for being unclear…

So, If I edit the TV, and paste int he emoticons, they are there - but if I close and save the TV entry - then edit them, they are already question marks.

They are questions marks in the database - so it’s as if on save, they are being converted.

I have just pasted them directly into the database with pypMyAdmin, and they are there - but sadly on the front end, they are still quesiton marks! I have cleared the cache before checking.

I also tried pasting emoticons directly into the Modx content field on a random resource, but if I repload the resource, they are converted to question marks too! I just wondered if it was the rich text editor causing it?

The table collation is set to: utf8mb4_general_ci

Did you also change the Character Set or only the collation?
You should change the Character Set!

Rich text editors typically don’t prevent emojis - definitely the collation/charset that’s breaking it.

Note that the collation is set on the table and individual columns, too. SiteDash has a database analysis tool that’ll quickly list out all collations for you.

Thanks mark - ok - I did atually change all tables and columns when i updated the collation.

No i didn’t change the character set - i can’t see where to do it!

I believe in phpMyAdmin this is only possible with an SQL command.
Something like this for a single table:


Maybe google for the correct command and make a backup of your database first.

Or maybe I’m wrong and changing the collation in phpMyAdmin changes the charset as well. The fact that you can enter emoticons into the database directly would indicate that.

I not sure if that helps, but the charset is also defined in the file core\config\config.inc.php ($database_connection_charset and $database_dsn). Maybe this has to be changed to.

Take a look at this. The code should be modified to use the utf8mb4 set, but I haven’t had the time.

Thanks Bob - that’s brilliant!

Thanks harry - I tried this but it lockd me out of Modx - I couldn’t login until i changed back to the standard UTF-8!

Got there with yours and Bobs help though - thanks again for all your input!

This topic was automatically closed 2 days after discussion ended and a solution was marked. New replies are no longer allowed. You can open a new topic by clicking the link icon below the original post or solution and selecting “+ New Topic”.