Notifications
Clear all

[Solved] Emojis now showing as question marks all of a sudden!

41 Posts
5 Users
17 Reactions
3,384 Views
Posts: 93
Topic starter
(@nutritionchat)
Estimable Member
Joined: 4 years ago

Hi @blackraz - apologies, but I will not be able help further as I don't have access to a different host to use. Let me know if you have any other suggestions.

It will be interesting to see if other WPforo users on LiteSpeed servers also experience this issue (although I wonder how common emojis are ?)

Posts: 93
Topic starter
(@nutritionchat)
Estimable Member
Joined: 4 years ago

As a test, I pasted all the emojis from here on Wikipedia into my forum here (several replies).

Weirdly, a few of them do stilll work, specifically:

✌️
✍️
☕️
☄️
❤️
❄️

In addition, I can enter characters to auto-generate a smiley, like this: : ) ... : - ) ... etc

🙂

🙂

😀

😉

I have no idea what these few have in common, to make them display OK !

↙️↙️⬅️↖️↘️↗️⬆️⬇️➡️

✨ Sparkles
✅ Check Mark Button
⚡ High Voltage
⏩ Fast-Forward Button
⏪ Fast Reverse Button

Posts: 93
Topic starter
(@nutritionchat)
Estimable Member
Joined: 4 years ago

Hi @diegopino 👋 ... hope you can help!

I see that you had this exact same problem a few months ago >

Could you tell me how you managed to solve it?

What did your host have to do, to fix the problem?

🙏 

https://wpforo.com/community/how-to-and-troubleshooting-2/emoji-error/

9 Replies
(@nutritionchat)
Joined: 4 years ago

Estimable Member
Posts: 93

(diego replied here via his own forum - no solution found)

(@diegopino)
Joined: 6 years ago

Estimable Member
Posts: 62

@nutritionchat Hi friend.

With that code can Fix the emoji?

 

i will like to enable the emoji ok in my web.

 

thanks in advance

 

(@nutritionchat)
Joined: 4 years ago

Estimable Member
Posts: 93

Hi @diegopino 👋 

This was an issue with WPforo, that was fixed with an update - make sure your plugin is up to date.

This will fix the display of newly posted emojis going forward.

BUT unfortunately all your old emojis will stay as question marks.

(@diegopino)
Joined: 6 years ago

Estimable Member
Posts: 62

@nutritionchat Thank you for support.

i am test with new emojis, only display heart emoji and coffe emoji 😳 

https://winningeleven-games.com/wordpress/postid/16797/

i haved all update, the wpforo core and plugins.

well... maybe its not for my community the emojis 😢 

 

(@nutritionchat)
Joined: 4 years ago

Estimable Member
Posts: 93

Hi @diegopino - apologies - I thought the devs would have rolled this out in a fix by now.

Looks like you still need to add this code by @BlackRaz into your FUNCTIONS.PHP.

To help do that, the CODE SNIPPETS plugin is great.

BlackRaz
Admin
(@blackraz)
Joined: 8 years ago

Contributor
Posts: 406

@diegopino @nutritionchat
We have incorporated the provided snippet of PHP code into the core of wpForo. Please anticipate the next release, wpForo 2.2.9, as it is expected to resolve any issues related to newly created emojis.

 

(@nutritionchat)
Joined: 4 years ago

Estimable Member
Posts: 93

Great, @blackraz 🙏 

Do you know if keeping my code snippet will cause an issue?

BlackRaz
Admin
(@blackraz)
Joined: 8 years ago

Contributor
Posts: 406

@nutritionchat 

There is no significance in keeping the previously provided snippet after updating to the new version of wpForo 2.2.9 because the code is now included in the core of wpForo.

(@nutritionchat)
Joined: 4 years ago

Estimable Member
Posts: 93

@blackraz ... Ok thanks ... hope I remember to remove it when the update drops!

Posts: 93
Topic starter
(@nutritionchat)
Estimable Member
Joined: 4 years ago

Hi @blackraz ... or maybe @chris or @robert could help? 🙂

To recap: all emojis display OK in a normal WP page, no problem (here).
When I add emojis into a forum post, they display OK at first, but are lost when I save the forum post, turning into '??' as here.

It looks like it's not only me with this issue, but I am no good with databases!

I wonder if you could pass these links onto your tech support ? Maybe they will help at your end, or you could advise on action from my side?

Mysql unable to store emoji in utf8mb4 collation

Wordpress : Unable to save or update posts with Emoji

Database restore does not retain emojis

3 Replies
Robert
Admin
(@robert)
Joined: 9 years ago

Support Team
Posts: 10586

@nutritionchat ,

I think this should be fixed from the hosting side. You should contact them and ask them to fix the database. Something is wrong with the database and this cannot be fixed from wpForo plugin for sure.

You can try to clone your website to a new very cheap hosting to check it.

I'm really sorry but I don't see any solution at the moment.

(@nutritionchat)
Joined: 4 years ago

Estimable Member
Posts: 93

Thanks @robert 🙏 

Yes, I already raised a ticket with my host, and they said that as the database is saving normal posts/pages correctly, and the issue is only affecting WPforo, then it's a WPforo issue!

Maybe WPforo saves its data uniquely somehow on Litespeed servers ? (I have no idea).

As this is affecting very few people, I guess that if I were to restore to a different (non-Litespeed) host, then the issue would not arise.

dimalifragis
(@dimalifragis)
Joined: 4 years ago

Famed Member
Posts: 2615

Posted by: @nutritionchat

Maybe WPforo saves its data uniquely somehow on Litespeed servers ? (I have no idea).

NOT an issue related to LiteSpeed (Commercial) servers.

 

Posts: 93
Topic starter
(@nutritionchat)
Estimable Member
Joined: 4 years ago

This code is provided as a solution for some setups, when added to functions.php .

I am not a coder ... Could you help me to customise it for use with WPforo ?

add_filter ( 'wp_insert_post_data', function ( $data, $postarr ) {
    if ( ! empty ( $data ['post_content'] ) ) {
        $data ['post_content'] = wp_encode_emoji ( $data ['post_content'] );
    }
    return $data;
}, 99, 2 );
3 Replies
BlackRaz
Admin
(@blackraz)
Joined: 8 years ago

Contributor
Posts: 406

@nutritionchat

This is a function similar to wpForo, but I'm not sure if it will be helpful for your specific situation.

function wpf_body_wp_encode_emoji( $post ){
        if( wpfkey( $post, 'title' ) ) $post['title'] = wp_encode_emoji( $post['title'] );
	if( wpfkey( $post, 'body' ) ) $post['body'] = wp_encode_emoji( $post['body'] );
	return $post;
}

add_filter( 'wpforo_add_post_data_filter', 'wpf_body_wp_encode_emoji' );
add_filter( 'wpforo_edit_post_data_filter', 'wpf_body_wp_encode_emoji' );
add_filter( 'wpforo_add_topic_data_filter', 'wpf_body_wp_encode_emoji' );
add_filter( 'wpforo_edit_topic_data_filter', 'wpf_body_wp_encode_emoji' );
(@nutritionchat)
Joined: 4 years ago

Estimable Member
Posts: 93

GREAT NEWS @blackraz ... IT WORKS !

https://dvdforums.co.uk/community/postid/4153/

Thanks so much for your help and patience in sorting this out !

🍻 🥂 

(@nutritionchat)
Joined: 4 years ago

Estimable Member
Posts: 93

aah ok ... @blackraz & @robert

Emojis in the post body now display perfectly ! 👍 

But do not show in the post titles. 

https://dvdforums.co.uk/community/suggestions/emoji-title-test/

EDIT - I should have said, I created the post first, to give a good URL, then I edited it to add the emojis (I do this for every thread).

Page 3 / 4