I have a bit of PHP that gets data from a MSSQL database and saves it to an array:
while($row = mssql_fetch_array($dbquery, MSSQL_NUM))
{
$content = array(
'something' => $row[1],
'something_else' => $row[2]
// etcetera
);
}
(The reason why I write the data to an array like that is not relevant I think, but if you must know: it is because the data is parsed by ExpressionEngine (EECMS). The PHP code is part of a plugin I am developing and this is the easiest way to make the data available for use in ExpressionEngine tags.)
Some of the data in de MSSQL database contains punctuated characters, such as ë and é. The diaeresis (ë) are shown as question marks in the HTML. For instance, Cliënten
is shown as Cli�nten
.
The HTML is in UTF8: <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
I cannot change anything in the MSSQL database. What is the best way, preferably in PHP, to fix this?