I’m having a weird problem regarding PHP and charset encoding..
I am developing a PHP Page that outputs some latin (ã, á, à, and so on) characters.
When I run the page from my localhost, it works just fine. However, when I upload it to my test-server and access it via a url, then all latin characters become little squares (in IE by the way).
I’ve changed the character encoding on my browser back and forth to utf8, western european and so on, but none seem to work
Does anybody have an idea?
Either set the
default_charsetinphp.initoUTF-8, or if you don’t have the control over this, add the following line to the top of the PHP file, before you emit any character to the response body:See also: