HTML and CSS Reference
In-Depth Information
<meta http-equiv="Content-Type"
content="text/html; charset=UTF-8" />
The charset=UTF-8 part warns browsers that they're dealing with UTF-8 if they haven't figured it out already.
Finally, you want to configure the web server so that it too specifies that the content is UTF-8. This can be
tricky. It requires access to your server's configuration files or the ability to override the configuration locally.
This may not be possible on a shared host, but it should be possible on a professionally managed server. On
Apache, you can do this by adding the following line to your httpd.conf file or your .htaccess file within the
content directory:
AddDefaultCharset utf-8
You really shouldn't have to do all three of these. One should be enough. However, in practice, some tools
recognize one of these hints but not the others, and the redundancy doesn't hurt as long as you're consistent.
I do not recommend adding an XML declaration. XML parsers don't need it, and it will confuse some browsers.
Search WWH ::

Custom Search