I have an issue with inserting and updating entries with special characters.
For example updating: After building the $updateArray I have the following function:
public function updateVideo($id, $updateArray) {
$this->db->where("ID", $id);
return $this->db->update("videos", $updateArray);
}
But when a value has a special character, for example á, it updates the database entry with Ã. This is with every special character (éáèà etc.).
I dumped the $updateArray, and the special character is fine there. I echo'd the last query, and it is also fine there. Even if I directly run the last query in phpMyAdmin it is fine. It seems to go wrong after building the query, so when executing it.
The column in phpMyAdmin has latin1_swedish_ci. I have set $config['charset'] = 'iso-8859-1';. The database config also has 'char_set' => 'latin1', 'dbcollat' => 'latin1_swedish_ci'.
Can someone help me pinpoint where I go wrong? Thanks!