[General Topics] Menneisyys:
I’ve just received a question from one of my blog readers about how the built-in Web browser in the Pocket PC / Windows Mobile operating system, Pocket Internet Explorer (PIE) / Internet Explorer Mobile (IEM) can be configured to request pages in different language than US English if you use an English language Windows Mobile operating system.

As this question is a very interesting one and very few people have the necessary HTTP- and actual programming (let alone offering a proxy server for free that does the trick!)-level knowledge to answer this question, I’ve decided to write a complete article on it.

What's the point? When can this be useful?

There are a lot of Web sites that offer their content not only in English but also in several other languages. The most important example is Google or, for example, many blogging engines. For example, b2evolution(the engine used in the Smartphone & Pocket PC Magazine Expert Blogs) returns English pages by default. However, if you configure your local Web browser to request Web pages in another language, you'll receive Web content in that language.

For example, if you set your referred language to, say, Finnish, you'll get this (Finnish language) page instead of this (English original) when you try to log in. And, the list continues - there are a LOT of other pages, frameworks, content management systems that do take into account what language the client prefers and return their Web content accordingly.

Making use of this capability can be of enormous advantage for people that don’t really have a good command of English and would like to prefer content or, at least, menus and dialogs in their native tongue.

How can you instruct desktop Web browsers to request Web pages in the language of my choice?

With Internet Explorer, go to Tools/Internet Options/ General and click Languages in the Appearance group. Then, just click the Add button and choose the language you prefer from the list. Make sure you move it up the list (with the Move Up button) so that it'll be your primary language.

As far as the desktop Opera browser is concerned, I'll elaborate on it later.

The desktop Mozilla/Firefox must be configured in exactly the same way as the Pocket PC version (screenshot) - see below.

OK; now, how I configure my Pocket PC Web browsers to do the same?

It's, unfortunately, a bit more complicated. Read on!

A bit geeky stuff: HTTP and Accept-Language

(Note that understanding this section is not needed if you aren't a tech / geek type of person. However, trying to digest it can be very useful to understand my HTTP request header screenshots and to understand how, for example, my proxy servers work.)

First, to understand how the HTTP servers (that is, Web servers) are able to decide in which language they should return the requested Web page, it's very important to know that the HTTP protocol (the protocol used in communicating between a Web server and a browser) uses so-called 'HTTP request headers'. These requests tell the Web server what resource to get, whether it's cached on the client (so that the server only needs to return the resource again if it's been changed in the meantime), whether the client has 'cookies' stored about the server to maintain Web sessions and so on.

One of these headers is called 'Accept-Language' and tells the Web server what language the client prefers (with, optionally, an additional country code and/or quality setting when there is a list of preferred languages). For example, if you'd prefer pages in Finnish instead of the default English, this header looks like the following:

Accept-Language: fi (or, Accept-Language: fi-FI - both are valid and can be used. The first, lowercase 'fi' stands for Finnish, the second, uppercase 'FI' stands for Finland. Note that, in general, the country code can also be lowercase; from now, on, I use lowercase letters to denote the country.)

If you'd prefer your preferred language to be Canadian French, you can use the following request header:

Accept-Language: fr-ca

And, as far as strictly US English is concerned, you'll often see this header:

Accept-Language: en-us

In order to be able to return a Web page tailored for your language preferences, the Web server MUST receive every HTTP request (Web page download) containing the Accept-Language header. If it doesn't receive it, it will in no way know what is your preferred language and will, in almost all cases, return the default one (English in most cases).