2

I've inserted some data to a mysql database. Set up the utf-8 cz. And it looks fine. enter image description here

But when I echo a row from the table, special characters are not shown. Meta utf-8 included. enter image description here

Any ideas how to fix it? Thank you

davidkonrad
  • 83,997
  • 17
  • 205
  • 265
user1505027
  • 323
  • 2
  • 8
  • 14
  • Is your page generating utf-8 encoded output? If your webserver encoding defaults to other codepage, it's the way browser interprets it, rather than mysql issue. – favoretti Oct 13 '12 at 14:20

2 Answers2

4

use

mysql_set_charset('utf8');

before you execute the query in PHP

davidkonrad
  • 83,997
  • 17
  • 205
  • 265
0

add this too your too to ensure browser's read your page with the right encoding:

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
aleation
  • 4,796
  • 1
  • 21
  • 35