WalterSteiner Posted August 26, 2014 Share Posted August 26, 2014 hello guys, i'm new here, looking for some help..here is the situation: i'm using utf-8 to input japanese characters onto a database mysql, using php form, however while done from my PC it works perfectly and the script records the characters correctly onto the DB, BUT on other PCs the script inputs raw symbols, i've declared completely all the things regarding the UTF-8 header, meta tag, etc. i'm sure this is not a php/sql issue, (because it works perfectly from one pc) but something from windows configuration i cannot understand. anyone knows something regarding this issue?? thanks in advance Quote Link to comment Share on other sites More sharing options...
Jacques1 Posted August 26, 2014 Share Posted August 26, 2014 What's a “raw symbol”? Anyway, my guess is that you forgot to declare the character encoding of the database connection. In that case, MySQL will use the default encoding from the configuration which can differ accross systems. How the encoding is declared depends on the database interface you use. If you're still using the ancient mysql_* functions, it's mysql_set_charset(). If you're using MySQLi, it's mysqli_set_charset(). If you're using PDO, it's the charset parameter of the DSN string. Do not change the encoding with a SET NAMES query. While many people suggest this, it's very wrong, because it doesn't update the encoding information of the MySQL API and can break critical functions like mysql_real_escape_string(). Quote Link to comment Share on other sites More sharing options...
Digitizer Posted August 26, 2014 Share Posted August 26, 2014 one usual problem is language not supported on other clients... happened to me a lot in unicode Urdu, the charactes appeared raw Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.