I get null results after I do a ajax call, where the values have umlauts. I tried to fix this with:
$this->pdo = new PDO('mysql:host=host;dbname=db','user','password',array(PDO::MYSQL_ATTR_INIT_COMMAND => "SET NAMES utf8"));
The call hierarchy is that the ajax call goes to a php script search.php which have stored a dbconnection object and this is where the sql-calls are going on. I also tried to fix it with utf8_encode but it had no effect. The database is in charset: UTF-8 Unicode (utf8), too and the php version is 5.4.
In my local apache I dont get any problems. The problem apears only on the real webpage.
What do I miss?