PHP+MySQL charset problem
| From: | Roman Serbski | Date: | Wed, 17 Jan 2001 08:22:37 +0000 |
| Subject: | PHP+MySQL charset problem | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-34993@lists.php.net to get a copy of this message | ||
Good day all!
Please help me with charset. I have some strange trouble.
I use FreeBSD 4.2 STABLE and MySQL 3.23.28-gamma (compiled from FreeBSD
ports) and PHP 4.04.
Latin1 is a default charset in MySQL. So, I wanted to add cp1251 or koi8_ru.
Ok, I add --default-character-set=cp1251 to my mysql start-up script.
The problem is:
If I connect from console to mysql and type \s (to get status information)
it shows: Language: cp1251
Everything seems OK, but if I try to connect via phpMyAdmin 2.1.0 or Horde
1.2.3+Imp 2.2.3 (webmail implementation) it returns -
<<For phpMyAdmin>>
Warning: MySQL Connection Failed: Can't initialize character set 14 (path:
default) in /usr/local/www/htdocs/adm/lib.inc.php on line 255
Error
<<For Horde>>
Warning: Can't initialize character set 14 (path: default) in
/usr/local/lib/phplib/db_mysql.inc on line 73
I don't know where is my mistake? I tried to contact MySQL mailing list -
thay said this problem has nothing to do with MySQL.
I do have sql/share/charsets folder with Index and cp1251.conf. I checked
Index - records are OK.
Should I add something to /usr/local/lib/php.ini file?
Looking forward to hear from you.
Regards,
Roman