I have a simple text into my database with a string like this:
“Online il nuovo sito web di QINT’X: rinnovato nella grafica presenta una struttura più lineare e facilmente fruibile rispetto al precedente, a tutto vantaggio della navigazione”
I have make a query in PHP to retrieve data but when I take the string doesn’t decode the character’ù’. Why?
This is my code (I have hidden the part of query because the problem I think is in the utf8_decode):
echo'<span class="txt_page" style="text-align:justify">'.utf8_decode(htmlentities(substr($news['descrizione_it'],0,200))).'</span><br />';
You should set encoding when you connect the DB.