Unknown character on webpage but shows up right in database

My website URL is:
http://tokoldrag.epizy.com/index.php?fname=bognar&order=402time

What I’m seeing is:
“�” Unknown character in names but the coding is UTF-8 and it shows up correctly in the database, but not on the website

What could cause this issue? Everything is coded UTF-8

Other UTF characters seem to be fine on the webpage except the ones that come from the database, but in PHPMyAdmin they show up properly.

Maybe try to set the tables’ character set to utf8mb4 and the collate to utf8mb4_unicode_ci, and then configure your software to use those instead of the default values?

1 Like

I have tried utf8mb4 coding, but didn’t help

I see the HTML charset returned right now is utf8mb4_unicode_ci. However, I don’t think that’s a valid charset. The entire concept for utf8mb4 is just a MySQL quirk, and doesn’t really exist anywhere else. Same for the

Could you change this to UTF-8 and see if this works?

Also, the collation of your tables and columns is currently configured to be utf8_hungarian_ci. I don’t really know what the consequence of that setting is, but I would recommend to use utf8mb4_unicode_ci by default, which should work well with any characters in any language.

Character encoding is enough of a headache when you don’t mix languages and encodings, so it usually helps to keep things simple.

3 Likes

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.