Y
Y
Yarik2020-09-13 16:18:27
PHP
Yarik, 2020-09-13 16:18:27

Storing and converting emoji?

The site has support for emoticons in the form of pictures (as in VK).

Here is my algorithm:

1) the user has selected a smiley;
2) after pressing the 'Submit' button on js, the smiley image is converted into its Unicode representation, and it is further stored in the database;
3) When rendering the page, I needed to do a reverse conversion, the script of VK itself helped me, the conversion is done after loading the page using js, here is the main problem, first the default unicode smiley is shown, then the script does the conversion into a picture.

The question is, can the last stage be redone somehow, if so, how? So that the image is immediately displayed when loading.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question