issues with certain characters displaying correctly on websites

We just moved some sites over from another host to our virtualmin setup and a site is having issues with certain characters on their site. The pages are in .php

It should like this: Saint-Pée-sur but shows like this: Saint-Pée-sur

How can I make sure those are displayed correctly? The site and servers are in english.




tpnsolutions's picture
Submitted by tpnsolutions on Wed, 02/17/2010 - 20:11


This sounds like a "character encoding" issue.

Generally speaking, you should try to use the "UTF-8" encoding for international documents, as it's pretty universal, and widely used.

This can be set at the document level by adding the following into your HTML code in the "head" section:

<meta content="text/html;charset=utf-8" http-equiv="content-type" />


You can set it up in Apache's configuration file like:

AddDefaultCharset utf-8

*** This can also be done in the global scope as well. ***

More information on Apache's implementation can be found at:



Thank you for the detailed reply. I have that set and html with those characters seem to display correctly but on their blog that uses php all their posts with special characters have issues. The blog is set to use UTF-8. If you have any other ideas that would be great.

Thanks again.

tpnsolutions's picture
Submitted by tpnsolutions on Thu, 02/18/2010 - 01:35


It may be the "Default Collation" in MySQL if it's information published in the database which looks mangled.

Often times a server's "Default Collation" is set differently on the original server, and the destination server.

Please check out the article below which I believe may correct your issue:



I must be something with the blog because I deleted the original mysql db, created fresh with UTF-8 for collation and got the same results. I was able to edit several posts and they take the characters fine and display them but the old data is still munched. Thanks for your time. It's appreciated!