I am trying to insert a Utf-8 string into a cell with utf8_general_ci collation
My code is:
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"> ... print mb_detect_encoding($name); $query = "INSERT INTO items SET name='$name', type='$type'"; print $query; mysql_set_charset('utf8');
What I see in the html output:
UTF-8 INSERT INTO waypoints SET name='ΔAS', type='ts'
What I see in the database, as name in the inserted row:
?AS
Now my row is utf-8, my table and cell are utf-8 .. why is the encoding incorrect?
source share