The new language detection stuff on php.net doesn't work with Apple's new browser, Safari. Whenever I try the manual shortcut (like /echo), I get a japanese manual. For your information, Safari sends its language string (according to phpinfo()) as
en-us, ja;q=0.48, es-es;q=0.93, es;q=0.90, it-it;q=0.86, it;q=0.83, pt-pt;q=0.79, pt;q=0.76, fr-fr;q=0.72, fr;q=0.69, de-de;q=0.66, de;q=0.62, nl-nl;q=0.59, nl;q=0.55, ja-jp;q=0.52, en;q=0.97, da-dk;q=0.45, da;q=0.41, fi-fi;q=0.38, fi;q=0.34, ko-kr;q=0.31, ko;q=0.28, no-no;q=0.24, no;q=0.21, sv-se;q=0.17, sv;q=0.14, zh-cn;q=0.10, zh-tw;q=0.07, zh;q=0.03
I'm not sure how one parses this, but it appears that en-us should be easily detectable as the primary language.
Parsing:
1. split by ","
2. foreach element from the previous split
2/1. split by ";"
2/2. use the first result of the split
So the above accept-languages final list starts with:
en-us
ja
es-es
es
it-it
it
pt-pt
pt
[...]
So the q values are removed, which are not important for us. The this list is added to the language selection priority order if the elements are acceptable for the site. Well, we don't have a manual under the "en-us" name, so "ja" is choosed for you, as your preferred language. Language codes are basically the dir names on php.net, and we don't have en-us, en-gb and the like...
Anyway, up until yesterday I was finding the manual shortcut to be very useful, but now it's very annoying, because I have to change to the english manual whenever I use it.
Well, I don't know Safari, but you probably can change these language settings somewhere. It should not be wired in...
Do you think we should convert en-us and en-gb to en while processing the accept language string?
Goba