Vítor Campeã Vítor Campeã - 15 days ago 5
PHP Question

php - trying to print some special characters

I have been trying to print some characters on my php page and it returns something else, like corrupted characters

like


"joão", ø, ç, etc


echo '<br>não<br>'


the return is

não


instead:

não


is this a problem with econding utf-8?

i have tried this code

header('Content-Type: text/html, charset=utf-8');


but no result

Answer

You have a typo in your Content-Type header. It's ...; charset=... with a semicolon.

Comments