chinese traditional from taiwan and the html lang attribute

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View
Hi guys,
I am creating a Taiwanese page and basically my problem is this:
The font on the page changes according to the html lang attribute.
zh (looks like zh-CN)
zh-TW (doesn't look the same, looks like zh-TW)
zh-Hant-TW (looks like zh-CN again)

to see the differences.

Now I would think I should use zh-Hant-TW  (hant = Han Traditional)
but I'm bothered that it displays the same as zh-CN (who use Hans =
Han Simplified) and not like zh-TW
I'm just confused on what it should really be set to.


Re: chinese traditional from taiwan and the html lang attribute

Mohawk Mawk wrote:

Quoted text here. Click to load it

That's supposed to be part of a solution rather than a problem, but in this
universe, solutions often turn into problems.

Quoted text here. Click to load it

This depends on the browser and its settings. The most widely recognized way
of specifying (in HTML) the version of Chinese writing system you're using
is lang="zh-CN" vs. lang="zh-TW", even though this can be regarded as
illogical (as many other features of the language code system).

Quoted text here. Click to load it

It would be most logical to use zh-Hant if you wish to specify the writing
system variant only, and zh-Hant-TW if you additionally wish to specify the
language variant by area. But logic has its cost, and zh-TW is a practical

On the other hand, the lang attribute has an effect on the rendering of
Chinese text only when the font is not specified in HTML or CSS in an
effective manner. If you set, say,
* { font-family: Arial Unicode MS; }
then lang attributes won't affect rendering of those characters that exist
in Arial Unicode MS as installed (if it is) on the user's system. I'm
deliberately mentioning a dull font here. The point is that if you can write
a list of suitable fonts so that at least one of them is installed on most
Chinese users' systems, then you can ignore the lang attribute as fas as
rendering is considered. It is good to use language markup as a matter of
principle, but it has surprisingly little effect in practice.

For your information, though I'm not sure at all whether you need it, the
factory settings of IE 7 on Vista use by default PMingLiU for  text
recognized as traditional Chinese and SimSun for simplified Chinese. So
using a font-family declaration including (e.g. as the last one in the list)
PMingLiU, you effectively get the same rendering result for Vista users as
using lang="zh-TW". I'm pretty sure there are web resources about Chinese
font that let you plan the strategy more accurately.


Site Timeline