"Yossi P" <an*******@disc ussions.microso ft.com> a écrit dans le message de
news:85******** *************** ***********@mic rosoft.com...
I'm developing a Hebrew-based web site and wondering wether it would be better
to set a specific hebrew charset or UTF-8. As far as I understand the the
biggest diffrence is that utf-8 consumes double-size (unicode) characters when
saving data to the DB (-that's fine with me).
UTF-8 is basicaly ASCII whenever characters used are strictly ASCII. It uses
multiple bytes whenever characters are non-ASCII. Are you sure your DB system
doesn't translate to Unicode (UTF-16) instead?
My concern is, however, how does the explorer "know" if clients of my site have
the right fonts ? I mean that if I'm using a specific charset in my web-site (i.e.
"windows-1255" - Hebrew charset) and someone enteres my site, if he doesn't have
the right fonts, the explorer posts a fonts-download-message. How can the
explorer guess the required fonts when there is no specific indication for that
in the HTML ?
This is why there are recommendations : for instance always provide an alternate
language whenever possible. However modern browsers support multiple languages.
They also can offer a language detection and ask the user to install the
corresponding character set, just like MSIE.
If your pages will be viewed by anybody around the world, why not use English as
an international language? If it's not possible, you should provide a default
web page that explains why you made such choices.
There are ways to detect the language someone's browser is "using", i.e. the
HTTP Accept-Language headers. However you won't get 100% results as there might
be still browsers that don't send such headers.
If you use HTML language indications (lang attribute, see HTML specifications:
http://www.w3.org/TR/html401/) properly, browsers which support them will be
able to interpret them and to prompt adequate choices to visitors.
Hope this helps.
Vince C.