Good morning everyone, Use as hosting, HOSTINGER and after trying to contact the technical service and not solve the problem I come to the experts of this forum.
I am doing a webservice in php, I have already managed to store characters in the database with accents or ñ, but when sending them back there is no way, I get strange symbols ...
I'm doing this:
$consulta="SELECT emei, obsServicio FROM 'voluntarioServicio' WHERE 'id'= ".$id;
$resultado= mysqli_query($link,$consulta);
$arraySalida = array();
while($registro = mysqli_fetch_assoc ($resultado) ):
$cadena = "{$registro['emei']};{$registro['obsServicio']}";
$arraySalida[]= $cadena;
endwhile;
echo utf8_decode( implode(":",$arraySalida));
But it should not work entirely correct since it does not decode the accent that does appear in phpMyAdmin, I think the solution is to put the utf_decode () in $ regristo [''], but I do not know how ...
I have also tried:
echo implode(":",utf8_decode($arraySalida));
but still showing odd characters
Any ideas?
PS: I've also tested htmlspecialchars () and htmlentities () for trying more decode functions