I'm trying to develop a simple PHP page that allow me to print some data in a database. The problem is that some data aren't "clean", i think that in the data there are some html tag (i suppose).
An example of data is the following:
%3Ch1%3E%3Cspan+style%3D%22color%3A+rgb%280%2C+0%2C+51%29%3B%22%3EDirettore+Artistico%3C%2Fspan%3E%3C%2Fh1%3E
To solve my problem i tried this:
<?php
$result = mysql_query("SELECT text FROM mutable WHERE (id_obj = 1)");
while($row = mysql_fetch_array($result)){
echo "<p>" . html_entity_decode($row['text']) . "</p>";
}
This solution don't work, i don't know if is important but the charset of my db is : latin1_swedish_ci