On 7/6/06, Santiago del Castillo <[EMAIL PROTECTED]> wrote:
Hi, i'm having a bit of a headache with PHP and MySQL, i've some questions:1) I've a database in UTF-8 and when i connect to it with mysql_connect, and exec a query with mysql_query, the results are in latin1. (i proved this with mysql_query("show variables like 'char%'"); 2) Is there any way to force mysql to make connections in utf8? here is the mysql status command report:
In my scripts I issue these commands on connect. This seems to resolve the problem for me. I cannot change it in my.cnf since changing the default from latin1 to utf8 would break previous sites. SET NAMES 'utf8' SET collation_connection = 'utf8_unicode_ci' -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]
