User97798 User97798 - 2 months ago 5x
MySQL Question

Unable to fetch characters as in Mysql database

Unable to fetch characters as in MySql database below is the table.

| APH | ID0 |
| A | Costa Rican Colón |
| B | Icelandic Króna |
| C | Somali Shilling |
| D | Nicaraguan Córdoba |

when i get the from db by using PDO in php
then the above character shown like this

Costa Rican Col�n

what should i do?


After fetching from mysql you need to use htmlentities like below in PHP

$str = htmlentities('Costa Rican Colón');
echo $str;exit;