UTF-8 Compatible

From CSWiki
Revision as of 16:46, 15 January 2007 by Savvasn (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Converting WebPages to UFT-8

grconv -T UTF -t is0-8859-7

Converting MySQL databases to UTF-8

Dump the db in an SQL file.

mysqldump -u root -p --lock-tables --default-character-set=greek dbname > dbname.sql

Edit the SQL file and insert the following two lines at the beginning of it.

CREATE DATABASE <dbname> DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;
USE <dbname>;

Telling MySQL to query in UTF-8 mode

Letting PHP know that you are working with UTF-8