UTF-8 Display for HTML - html

I have some special characters in UTF8 format which I want to display. First I tried to read the origin (JSON) as UTF8 having also any kind of UTF8 meta tags in the header:
<meta charset="utf-8">
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
<meta http-equiv="content-type" content="application/json; charset=utf-8" />
As this did not work, I transfered the special characters to HTML syntax and tried (with and without the UTF-8 headers) to get it displayed. But somehow I even do not get this. Here is the text I can add in a simple HTML file, which is then not displayed correctly.
It's Possible! � Our Experiences
I also tried this page with the ISO-8859-1 charset, but this does not work as well. I hope someone can help me.
Thanks,
Katja

If � is literally the text you get in your JSON, there's nothing you can do. � is the HTML entity for the UNICODE REPLACEMENT CHARACTER �, i.e. the Unicode character which is inserted when something went wrong.
This points to the original text having been screwed up by the originator. There's no way to know what that character was supposed to be before it screwed up and got replaced by �.

Related

ISO-8859-1 not displaying correctly certain characters

In the website I'm developing there are several european characters such as ã or ç. I was told to change from UTF-8 to ISO-8859-1, but ISO doesn't seem to code these characters correctly, while UTF-8 marks several others as question marks. Right now, the tag on my header is this one:
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
Use only UTF-8 if you want to avoid problems, the ISO encodings will bring you nothing good.

Czech diacritic on HTML

I'm trying to make some text in czech, but I can't success :-/
Web is http://esn.zcu.cz/world/
formate of the file and in meta is iso-8859-2 which should allow czech chars
Your webpage has <meta charset="charset=utf-8"> and yet it isn't in UTF-8. Firefox interpreted it as ISO-8859-1, which makes vowels like éóí look okay, but then č you typed is being displayed as è.
Solution? You can fix the meta tag, but seriously, it's 21st century, you really should use UTF-8 everywhere. Convert the page to UTF-8, remove <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2"> and you'll be fine.
Note: your HTTP server returns this: text/html; charset=ISO-8859-1

HTML Encoding for French characters

I have a email template, that has French copy. If I load this email template up in IE I receive square boxes where the accented characters are. How can I combat this? I assume it is down to encoding?
Ensure the HTML template has the correct meta tag in the header for Content-Type.
You did not specify if the encoding is Latin1, UTF-8 or other - you need to find out first in order to use the right value.
Here is what a UTF-8 meta tag would look like:
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
Just make sure that the actual encoding of the textfile (I assume it'll be either ISO-8859-1 or UTF-8) is in accordance with the meta tag defining the encoding in the beginning of the file. e.g.:
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
see http://en.wikipedia.org/wiki/Character_encodings_in_HTML

Charset UTF-8 doesn't work (stuck with these ?-marks)

I have a Unicode problem... I´ve done this before but for now, I cannot understand
why the Icelandic letters don´t show up - I have those question marks again
Here is the url (very plain and short html5)
http://nicejob.is/new/
Everything I Google says: use the <meta charset="utf-8"> as I do.
Any suggestions?
Your page is already viewed as UTF-8. But your source code is not saved as UTF-8.
Please change the encoding of your source code file to UTF-8.
Not all browsers support HTML5-way tags yet
here you can see table of compability
Try this instead:
<meta http-equiv="Content-Type" content="text/html;charset=utf-8">
I can see a couple of issues.
The META should look like this:
<meta http-equiv="content-type" content="text/html;charset=utf-8" />
The <html> specified lang="en" which might be prone to confusing some browsers.
When I view the HTML from the browser, the question marks are encoded as 0xEF 0xBF 0xBD, which is the UTF-8 encoding for the byte order mark or BOM, aka U+FEFF. So, for whatever reason, the HTML is not transmitted as sensible UTF-8 (though it does seem to be valid UTF-8).
Probably you are using some text editor like notepad++,
and you didn't set up encoding to UTF-8 in that text editor.
What you have to do is to save the file with utf-8 encoding by using Notepad (the attached one with Windows).
Steps:
Save as ..
In the below options ... you will find encoding option choose UTF-8 ...
And save the file ...
Then add the line <meta charset="UTF-8" /> inside your file ...
And it will work.

latin characters showing in some parts of the page and not others

the page in question is Apple Amor
You can see that in the footer the spanish vowels seem to be showing properly , but in the slide down bar(header) they get messed up.
Any ideas why ?
Your page is encoded in ISO-8859-1. Wherever that header comes from, it is most likely encoded in UTF-8.
You would have to change the character set of your page to UTF-8 (that would probably have some consequences) or convert the incoming data from the header. I don't know where it's coming from, so it's hard to tell what the right method would be.
Mandatory basic reading on the issue: The Absolute Minimum Every Software Developer Absolutely, Positively Must Know About Unicode and Character Sets (No Excuses!)
Your page source shows that you're using:
<meta http-equiv=Content-Type content="text/html; charset=iso-8859-1">
Note that the above tag is not well formed. Where is its closing character "/"? Content-Type should be between double quotes.
Add this tag to your page and test:
<html lang="es">
If that doesn't solve your problem try to change the charset tag to:
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />