Croatian diacritics in MySQL db (utf-8)

Diacritical marks http://img98.imageshack.us/img98/3383/dijakritickiznakovi.gif

So, the symbols denoting the name of the display should be displayed in this way.
UTF-8 objects are listed below with the HTML header (utf-8) (here is the list: LINK )
And the last line shows what is stored in my database.
Column of the table db utf8_unicode_ci.
I believe that the characters in db should not be what they are in my case? They correctly appear on the page when loading from the database, but they all do not appear in the utf-8 table from the specified link. Even if I see them correctly, maybe someone else will not?

+3
source share
2 answers

Setting the encoding of the MySQL table is not enough - you also need to set the correct encoding for the client, the connection and the results, which by default may differ from server to server, making your database less portable: the same database contents may be displayed differently, moving to another server.

I have been saving Slovenian text in MySQL for some time, and this is what works for me:

  • The first thing you do after connecting should be to issue a SET NAMES utf8 request
  • , , , utf-8, : -, , UTF-8
  • , / : PhpMysqlAdmin .

, .

+4

, , HTML, . , , . UTF-8 .

, " " ( UTF-8 ISO-8859-1). - ( UTF-8 / <meta>), , , .

+3

Source: https://habr.com/ru/post/1719211/


All Articles