Japanese Characters Registering As Gibberish - html

I have the language pack for Japanese characters installed onto my computer so I can practice but when I put it into an html file and uploaded it to the server that I'm using, it displays as this weird gibberish.
The encoding is in utf-8 but it still appears this way?
http://kotonii.com/katakana.html

You should check your server configuration. It does not have a "charset" in the "Content-type" header and in absence of this, the browser will use its own default charset (usually iso-8859-1, a.k.a. 'Latin1').
Your server has this:
Content-Type: text/html
It should be this, for your browser to decode it as utf-8:
Content-Type: text/html; charset=utf-8
You can also add this to the page's <head> section, it helps if you are viewing it in the browser as a local file (but shouldn't be a substitute for the HTTP header):
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<meta charset="UTF-8">

Related

HTML Special Characters not rendered properly

I've setup VestaCP on a 2 identical Debian 7 Servers. Strangers on server one the special characters display properly out of the box, but on the Primary server, the special characters are not being rendered correctly, they give the black "?" instead. Both server's are exact same software and config. writes here..
I've tried setting
/etc/apache2/conf.d/charset
/home/admin/conf/web/apache2.conf
/etc/apache2/apache2.conf
in .htaccess
AddDefaultCharset UTF-8
AddCharset UTF-8 .html
but it doesn't resolve at all. Please help me.
Interestingly, the pages (quite and old site) use
in their header.
Please check page here : http://168.235.66.20:8080/
The data is encoded using Windows-1215 not UTF-8. You should convert it to UTF-8.
You should change in your HTML :
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
With :
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">

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

Different rendering of European characters on two pages of same site with same charset

I have a site which is supposed to show French, Spanish characters. There is this strange situation where two pages handle it completely differently.
Both pages share the same header file where I use this meta tag:
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
I also set the charset at the global level in IIS > MIME Types:
.asp text/html; charset=iso-8859-1 local
The pages are http://aer2.es/fr/ and http://aer2.es/fr/method
What could be the reason for this inconsistency?
The physical encoding of the other file is in UTF-8, instead of Windows-1252 (ANSI, ISO-8859-1 ... + other mislabelings you see fit)
You can fix it by opening the other file, for example, in notepad, hitting save as, and choosing "ANSI" from the Encoding dropdown menu and then using the new saved file.
Another way to do it is to change the meta tag in the other page to UTF-8:
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
however, when saving the change, you need to ensure that you are saving the file in UTF-8 encoding.

Meta tags and language

I have a website writteng in greek.
<meta name="keywords" content="" /> can I use greek language in content or just in english?
If I can write them using greek chars, do I have to add anything to meta tag?
Thank you
You can use any character you want from the character set you are using. Just make sure that your web server send the correct character set headers in the HTTP request. You may also add a <meta> element specifying the charset, but it's not strictly necessary.
I use UTF-8 in these examples as I think it's a code charset and prefer to use it myself. It's on its way to take over as the standard charset on the web.
HTTP header which should be sent by the web server:
Content-Type: text/html; charset=utf-8
Optional <meta> element for your document:
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">

How to set a charset header for a html page?

Even though i use the below meta tag to set the content-type and charset, i am not seeing the charset header in the firefox firebug debugger.
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
Any help is appericiated.
The meta tag does not affect the HTTP headers sent. (Long ago, it was kind-of meant to do such things, but apart some forgotten experiments, it never did.) It specifies the encoding to be implied if HTTP headers do not specify the encoding; so it’s really not equivalent to an HTTP header (as the name ´http-equiv` suggests) but a replacement, surrogate, Ersatz for an HTTP header.
The way to set the HTTP headers depends on the server software and its settings.
But if the headers do not specify the encoding, then the meta tag takes effect. You ca check via the View → Encoding menu in Firefox which encoding is being applied.
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
It is how you set charset header for HTML files,there is nothing wrong.
Why would you use firebug to check the Charset? Just right click your mouse key and from the context menu select view page info and it will give you the page charset.