views:

604

answers:

5

I'm trying to localize my aspx pages. I'm done with content localization using L10n features provided by .net f/w, like resource files. But I'm finding it difficult to set local data in page titles.

Most of the browsers, including IE and FF, shows content on window title with some boxes (FF will show properly localized text in tab, IE doesn't even do that). But its working fine in safari (on windows).

When I did a research it seems like this issue exits ONLY for some of the languages. For example, the Hindi version of BBC shows the title with boxes. But Arabic version shows the localized text in title.

Can somebody please tell me why this is happening? How we can solve this issue?

Note: My site is using Asp.net 2.0 / IIS

+3  A: 

I suspect this is a typeface issue. The browser title bar and other window ornaments are usually rendered by your OS, not by the browser itself, so if you've configured Windows to use a typeface that doesn't support the additional character glyphs required for Hindi, Arabic, etc., then you'll get the boxes instead. Within your actual pages, you're probably using a typeface which does include support for all these extended characters, which is why you're only seeing the problem on the window titles.

Safari uses its own rendering engine for everything including the window chrome, which is why it doesn't look like a normal Windows app, and why your localized titles are working.

You might want to try changing your Windows "Active Title Bar" font (under Display Properties, Appearance, Advanced) to something like Arial which covers the full set of Unicode characters, and see if this resolves the problem?

Dylan Beattie
@Dylan: Thanks much for your answer. I was also thinking in same lines. Anyway, I solved the problem in my machine by setting "Arial Unicode MS" font as you mentioned. But seems like I have to live with this issue, since I may not be able to control my users machines :(
Vijesh VP
I wouldn't worry about it. I think it's safe to assume that anyone browsing the web in Arabic is using a system font that can render Arabic glyphs. :)
Dylan Beattie
+1  A: 

For me, both the BBC sites you link to get the proper characters in the window title bar (using Firefox or IE, on Windows).

I suspect you don't have the right fonts installed, though I'm not sure entirely what fonts it is that you would be missing to cause this problem, particularly not if Safari works.

In any case, I think it's a problem with the configuration of your system, not with the site you're developing. Hopefully your target audience will have a correctly configured system to display their own language.

Mark Baker
A: 

It's a font issue, and not something you can fix on the server side. If the font used for title bar text is missing glyphs present in the font used for tabs, then it will appear correctly in the tab but not the title bar. That would also explain why Safari works -- it uses its own fonts and font rendering system for everything.

John Millikin
A: 

The problem has to do with where and how the browsers show the web page title.

IE shows the page title in the standard window title. IE doesn't do the drawing itself, but leaves that to the OS. The OS title drawing code uses the standard font, which depends on the OS locale. The default font on your machine probably does not have characters for the Hindi. hence the boxes.

Firefox does not do custom drawing in the title, so it shows the same boxes. However, FF draws the tabs using a font of its choice.

Safari does custom drawing of everything, including the window title and is using a font of its choice.

Franci Penov
A: 

I see no problems in the links you gave, FireFox 2 & 3, on Windows and Linux. Both on the window title and the tab title.

Osama ALASSIRY