Re: How to i18n better?

[email protected] (Tomas Kuliavas) Mon, 26 Apr 2010 13:35:37 +0300
Newsgroups php.i18n
Message-ID <[email protected]>
Andre Polykanine rašė:
> Hi everyone,
> 
> I'm new here and it's my first message.
> We are making a blog platform (http://oire.org/) which is provided in
> several languages (currently they are Russian, Ukrainian, and
> English).
> Now the i18n process is made as follows: we set a cookie on the site
> and depending on it we select the language to display the site in. We
> have three (currently) interface files: rus.lng, ukr.lng, and enu.lng
> (for English US). the format is the following:
> define ("MSG379", "Welcome!");
> etc. I know that PHP does support somehow exporting the strings into a
> .pod file. Maybe it would be better to do that? If so, how can I do
> it?
> Could you suggest me maybe a better solution than we currently have?

See http://www.php.net/gettext

Translations based on constants or variables are not maintainable. 
Translators will have to track changes in constants/variables.

Your translation method does not support plural forms. If you are 
Russian, you should know that '2 houses' and '10 houses' don't use same 
noun form in some languages.

-- 
Tomas