php stores emoji expressions in WeChat. Before storing in the database, I printed it on the page and the expressions can be displayed normally. Then after storing them in the database (utf8mb4), the expressions can also be displayed normally in the database. But what happens when PHP reads the expressions in the database and displays them on the page? .
Why is this? Does it still need to be transcoded or something?
emoji is an expression picture, but when it is saved to the database, it is the encoding corresponding to the saved picture. After you take it out, you still have to find the corresponding picture with the code!
As you said in the last sentence, it needs to be converted (but not HTML transcoding). Emoji is an emoticon and needs a map to associate it.
That is, encoding -> picture
For details, you can look at this open source project. It has everything I said, and it belongs to a specific example: