Just use UTF-8 for everything, and normally it will just work.
Reinis I.
2010-09-09 07:45:14
It shows like this: R�g on the webpage.
You need to instruct the webbrowser that you're displaying the webpage in UTF-8 and that it should interpret it as the same. Add the following to top of your PHP, before emitting any character to the output:
header('Content-Type: text/html; charset=utf-8');
Only the <meta>
tag is not enough. This is not used by the webbrowser. It's the response header which counts. By the way, Javascript's escape()
function is deprecated.