[MySQL]
Description = ODBC for MySQL
Driver = /usr/lib/libmyodbc.so
Setup = /usr/lib/libodbcmyS.so
FileUsage = 1
[ePaper]
Trace = Off
TraceFile = stderr
Driver = /usr/lib/libmyodbc.so
DSN = ePaper
SERVER = 192.168.1.102
USER =
PASSWORD =
PORT = 3306
DATABASE = OSSIIDB
config.inc.php ,把以下的變數都改為 utf-8 :
$cfg['DefaultLang'] = 'utf-8';
$cfg['DefaultCharset'] = 'utf-8';
這個看看裡面有沒有 utf-8 ,沒有的話就自己加進去:
$cfg['AvailableCharsets'] = array(
:
'utf-8',
:
);
這個把 FALSE 改成 TRUE
$cfg['AllowAnywhereRecoding'] = TRUE;
不過我在使用phpmyadmin登入時發現內文是亂碼?
而之前建立錯誤的無法在Ooo開啟的資料庫名稱反而在phpmyadmin內顯示出正確的中文字,怪了~
我確定我的瀏覽器編碼是utf-8,而且在Ooo有把資料庫指定utf-8
不曉得是不是平台的關係
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
# Default to using old password format for compatibility with mysql 3.x
# clients (those using the mysqlclient10 compatibility package).
old_passwords=1
default-character-set=utf8
[mysql.server]
user=mysql
basedir=/var/lib
default-character-set=utf8
[MySQL]
Description = MySQL driver
Driver = /usr/lib/odbc/libmyodbc.so
Setup = /usr/lib/odbc/libodbcmyS.so
CPTimeout =
CPReuse =
FileUsage = 1
Driver = MySQL
Database = ooo
Trace = Off
TraceFile = stderr
DSN = MySQL
SERVER = localhost
USER =
PASSWORD =
PORT = 3306
DATABASE = OSSIIDB
mkdir /var/run/mysqld
ln -s /opt/lampp/var/mysql/mysql.sock /var/run/mysqld/mysqld.sock
[MySQL][ODBC 3.51 Driver]Client does not support authentication protocol requested by server; consider upgrading MySQL client
mysql> UPDATE mysql.user SET Password = OLD_PASSWORD('newPassword')
-> WHERE Host = 'someHost' AND User = 'someUser';
mysql> FLUSH PRIVILEGES;