UTF8 How todo it right?
Hello everybody,
I have some charset problems and I found this link showthread.php?t=15283&highlight=character+set+problem
I changed the charset in the database to UTF8 and inserted this codesnipped:
function mysql_set_charset($charset, $link_identifier = null)
{
if ($link_identifier == null) {
return mysql_query('SET NAMES "'.$charset.'"');
} else {
return mysql_query('SET NAMES "'.$charset.'"', $link_identifier);
}
}
}
mysql_set_charset('utf8',$MyNameDB.php);
The mysql-Version is 5.5.22-1
But it doesn´t work. Then I converted the database to utf8_general_ci. I hope I did it right, because I don´t have any experience on php or sql.
Now I´m trying to change the
$ ckeditor_config["entities"] = false
in "true".
But where do I find this line? In wich folder/file?
Thanks for help,
Mo
New************************************** The solution *********************************New
Now it´s working.
Workaround:
First insert this code to the database Connection file in the folder Connections on your server: don´t choose PowerCMSConnection.php => the other one "yourNameFile.php" - it´s the name you gave to the connection in Dreamweaver
Before the end of file and php statement: "?>"
function mysql_set_charset($charset, $link_identifier = null)
{
if ($link_identifier == null) {
return mysql_query('SET NAMES "'.$charset.'"');
} else {
return mysql_query('SET NAMES "'.$charset.'"', $link_identifier);
}
}
}
mysql_set_charset('utf8',$MyNameDB.php);
<== Change $MyNameDB.php to your file name!!!!!!! Don´t forget!!!
Then change the following files:
admin_cms/contents_insert.php and
admin_cms/contents_update.php
Look for this line:
and change it to:
I hope this helps.
Bye, Mo
P.S. Man könnte ja auch mal Antworten komplett abgeben. So profitieren auch andere.