Answer the question
In order to leave comments, you need to log in
How to get rid of the conversion to a smiley text for writing to the database?
The entry in the database contains a column with a line like - "Тест; Тест тест тест: 📞 ⭐ "
, those contain emoticons. After certain manipulations related to the translation of the text language, json_decode(of this line) is executed and the line becomes "Test; Test test test: ⭐ ". In this form, the record does not occur in the database.
Encoding of both strings is UTF-8, checked with
mb_detect_encoding()
Answer the question
In order to leave comments, you need to log in
Encoding for both strings is UTF-8set utf8mb4 for tables and for connecting to the database, the encoding is backward compatible with utf8, nothing will fly away during conversion, and all utf8 tables will also be read normally. It makes sense to change the encoding only in those tables that will directly store emoticons, in other tables it is not justified.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question