Re: Where does the mysqli extension find the default connection charset?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Jean-Noël Rivasseau wrote:
> Hello there,
> 
> I'd like to know which configuration file or setting is used by PHP mysqli
> extension to know the default charset connection to the database.

mysqli (and also mysql) extension uses the default character set for
libmysql  This can be package dependend: Several distros deliver utf8 as
default, others latin1.

To be on the safe side, you should call mysqli_set_charset($link,
"utf8/latin1/whatever) to set the character set for each connection.

/Georg
-- 
Georg Richter, Development Manager - Connectors & Client Connectivity
MySQL GmbH, Radlkoferstr. 2, D-81373 München, www.mysql.com
Geschäftsführer: Hans von Bell, Kaj Arnö - HRB München 162140

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux