co.ador Posted August 15, 2009 Share Posted August 15, 2009 I have put this little script in the code to see what kind of charset is the scrip using <?php $link = mysql_connect('localhost', 'root', 'coloso'); $charset = mysql_client_encoding($link); echo "The current character set is: $charset\n";?> The current character set is: latin1 I have the database in mysql set to utf-8 and I don't know why it is displaying through the script above that it is set to latin1? I want to know if the script above it's displaying the character set of the database or the one of the script because the DB is set to UTF-8_general_ci and all the tables and TEXT, and VARCHAR fields to utf-8_general_ci I don't know why it is displaying Latin1 through the script above. Well I am glad to know that there is a conflict now between latin1 and utf-8 and that's what cuasing now to displaying some character which I have input in the database such as ú,á,é,í etc.. I am glad just need some of your help now to set up the script to utf-8 thank!! Link to comment https://forums.phpfreaks.com/topic/170345-my-script-or-the-database-is-set-to-latin1/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.