[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: php and locales



On Wed, 9 Jan 2002 10:40:28 +0100
Gaetano Paolone <bigpaul@debian.org> wrote:

> 1) has the original gettext source code to be written in english?
>    The software I am working on is not in english and so
>    it will generate a po in another language (italian).
>    I can manage to make the english po file (translating it) but I am sure
>    that it would be much more easy to translate this software
>    in russian starting from the english version rather than
>    from the italian one. But you know, the upstream version
>    is in italian so HAS it to be in english or not?
>    Has the upstream author the need to change all the code in english
>    or would it be a "good suggestion"?
theorically no, it can be any other language... if you keep en.po
updated, I can see no problems with translation...

> 2) I know that it should be automatic, but would it be 
>    stupid to put a php code to ask for the user's language
>    and then export the relative LC_ALL? (with the setenv
>    php command)
it depends on your application, if you feel it is needed, why not?

> 3) I have in /etc/enviroment "LANG=it_IT", all my consoles
>    are "localized" and everything seems to work quite well. 
>    The question is: Why PHP tells me that
>    the LANG variable is "C" instead of "it_IT"? (I read the
>    value with getenv php command). Where should php look for?
>    Have I forgot something in declaring my "localization"?
php is being run from inside the web server, probably? the
webserver doesn't know about /etc/environment, you will probably
need to specify your locale elsewhere...

hope it helps

[]s!

-- 
    Gustavo Noronha Silva - kov <http://www.metainfo.org/kov>
*---------* -+-+--+-+--+-+--+-+--+-+--+-+--+-+--+-+--+-+--+-+-+
|  .''`.  | Debian GNU/Linux: <http://www.debian.org>         |
| : :'  : + Debian BR.......: <http://debian-br.cipsga.org.br>+
| `. `'`  + Q: "Why did the chicken cross the road?"          +
|   `-    | A: "Upstream's decision." -- hmh                  |
*---------* -+-+--+-+--+-+--+-+--+-+--+-+--+-+--+-+--+-+--+-+-+



Reply to: