Re: [PHP-I18N] Encoding detection
by Atanas Vassilev other posts by this author
Mar 19 2001 12:12PM messages near this date
Re: [PHP-I18N] Encoding detection
|
Re: [PHP-I18N] Encoding detection
Thanks for your timely cooperation.
In fact following the direction you gave me I found out that
$HTTP_ACCEPT_LANGUAGE was what would work even better....
Something strange happened though:
I formed my include like this:
include "lang_".$HTTP_ACCEPT_LANGUAGE.".INC";
So, I have 2 files - lang_bg.inc and lang_de.inc. If I switch my regional
settings from Bulgarian to German-standard and browse the site with IE
everything's just fine - but if I try NS all of a sudden
$HTTP_ACCEPT_LANGUAGE has the value of "en" no matter if my regional
settings are Bulgarian of German.
Any ideas as to what the workaround for this would be?
Gustav Foseid <gustavf@[...].no> wrote in message
news:20010319091510.A13178@[...]..
> Atanas Vassilev:
> > I need a way to detect default browser encoding so that i can set a
> > variable for language and present the whole site in different
> > languages based on encoding. I know encoding does not determine
> > language but I only have to switch between german and bulgarian so in
> > my case encoding will do the trick... of course if I knew a way to get
> > the encoding of the user's browser...
>
> You have the information you need in $HTTP_ACCEPT_CHARSET.
>
> --
> Gustav Foseid, Initio IT-løsninger AS
> gustavf@[...].no
>
> --
> PHP Internationalization Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-i18n-unsubscribe@[...].net
> For additional commands, e-mail: php-i18n-help@[...].net
> To contact the list administrators, e-mail: php-list-admin@[...].net
>
--
PHP Internationalization Mailing List (http://www.php.net/)
To unsubscribe, e-mail: php-i18n-unsubscribe@[...].net
For additional commands, e-mail: php-i18n-help@[...].net
To contact the list administrators, e-mail: php-list-admin@lists.php.net
Thread:
Atanas Vassilev
Atanas Vassilev
Atanas Vassilev
Gustav Foseid
Gustav Foseid
|