Msg#: 4322329 posted 2:01 am on Jun 6, 2011 (gmt 0)
You can't simply change the meta tag. The file itself has to be changed concurrently from Latin-1 to UTF-8. How you do this depends on the editor, so I can't give detailed instructions. If you are on Windows, it probably involves something more complicated than changing a popup.
Currently your browser is trying to interpret Latin-1 text as UTF-8. This will not work-- especially if that Latin-1 is really Windows-Latin-1 (a superset of ISO-Latin-1). Some Latin-1 characters will simply come through as the wrong letter; others won't display at all. The angry black diamond is the "I can't deal with this" UTF-8 character, FFFD.
Oh yes and... You will also need to take a precautionary look at your uploading program-- FTP or whatever it is-- to make sure it isn't making the wrong assumptions about file encoding. For example, earlier versions of Fetch changed all my text files (for FTP purposes, "text" includes HTML) into Mac encoding. I don't remember if I changed a setting or if it simply learned to read the meta tag.
Msg#: 4322329 posted 11:03 pm on Jun 6, 2011 (gmt 0)
File and Remember:
If you use entities for all non-ASCII characters, it does not matter what encoding you declare. The term "charset" is misleading (boring historical reason which I won't go into, mainly because I don't remember it). It has nothing to do with what characters the document is able to display; it only refers to the relationship between the raw HTML file and what the user sees. Any HTML file can display any character.
To make things more fun, there are three ways to do entities. First are the HTML 4 named entities: é and so on. Long long ago when I used Internet Exploder 5.1 (the last Mac version), it was only able to display characters that had a named entity. You didn't have to use the entity-- you could use numbers or the actual character-- but it had to have one. (And it couldn't read the "charset" declaration, so you had to change that manually. I still include a blurb about it in all e-texts, though by now it's probably superfluous.)
Then there are the decimal numerical entities. My fingers do not like typing the word "entitities". Like "banana", they do not know where to stop. é for that same é, for a savings of two bytes-- set against an even higher level of unreadability in the raw file. And finally the hexadecimal entities é Doesn't save any space unless you get into big numbers where powers of 16 use fewer digits than powers of 10, but useful if your character map is hexadecimal to start with.
Now back to the original post. Just out of curiosity, why did you want to change encodings? Personally I use UTF-8 by default, but then I use a lot of non-ASCII and especially non-Latin-1 characters ;)