Haezer
Haezer

Reputation: 476

Emojis generated by emojize doesn't show in email

I'm using email and smtplib libraries to send an email. I'm trying to include emojis in this email, by using emojize.

Basically, I'm doing this :

my_emoji = emoji.emojize(":thumbs_up:")

my_message = f"blabla {my_emoji} blabla"

Then the message is sent using smtplib and email. It works, but not always. Some emojis will appears in the email correctly, but some will not. For example, :thumbs_up: works, but :heart: doesn't. Instead of the actual emoji, there will be written ":heart:" in the mail.

I don't think my code is the problem, that's why I only shown a sample. I think it has something to do with encoding, unicode or something like that (I barely know anything in those fields)

Can you help me ? Sorry for bad english.

Upvotes: 0

Views: 204

Answers (1)

qiweunvjah
qiweunvjah

Reputation: 142

Here's the problem. The heart should be :red_heart:. Make sure the spelling is correct.

Upvotes: 1

Related Questions