Bug 5152 - Accept-Language header incorrect locales, only 1 language
: Accept-Language header incorrect locales, only 1 language
Status: RESOLVED DUPLICATE of bug 3510
: WebKit
WebKit Misc.
: 412
: Macintosh Mac OS X 10.4
: P2 Normal
Assigned To:
:
:
:
:
  Show dependency treegraph
 
Reported: 2005-09-27 09:16 PST by
Modified: 2005-09-27 13:40 PST (History)


Attachments


Note

You need to log in before you can comment on or make changes to this bug.


Description From 2005-09-27 09:16:03 PST
Summary: The Accept-Language header that webkit sends is not properly dealing with locales (e.g. 
brazilian portuguese), and it only sends one language, even if you have defined multiple ordered 
languages in your system preferences.

To reproduce
* Open up System Preferences -> International -> Language
* Load <http://www.gmdc.org/publicapp/snoop.serv?testParm1=testVal1&testParm2=testVal2> (or 
any other web page showing you the HTTP headers

Now move the following langauges to the top of the list in System Prefs, and reload the page, noticing 
the value of the Accept-language parameter.

For instance  (view in a monspaced font):

Topmost Locale        Expected     Actual
--------------        --------     ------
British English         en-gb       en
Australian English      en-au       en-us
Canadian English (eh?)  en-ca       en-us
Portuguese              pt          pt-pt
Brazilian Portuguese    pt-br       pt-pt
German                  de          de-de
Swiss German            de-ch       de-de
Canadian French         fr-ca       fr-fr
Swiss French            fr-ch       fr-fr


The other issue is that according to <http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html>, you 
can specify multiple languages that your browser accepts; it seems that WebKit should take more than 
just the topmost language in AppleLanguages into account.
------- Comment #1 From 2005-09-27 13:40:00 PST -------

*** This bug has been marked as a duplicate of 3510 ***