On 19/06/07, Michael Jervis <
mjervis@...> wrote:
> When using gettext, is there any advantage to breaking your
> translation down into modules?
I've done a bit of investigation in light of the lack of other information.
It would appear that the gettext translation module parses the entire
.mo file into itself and uses that information to perform the
translations.
It's actually compiled into a PHP Array so.
1) The best practice would be to break your translation into a large
number of modules (if performance is your main non-functional
requirement but not if it's getting easy translations done!)
2) gettext is a more expensive version of using the arrays backend.
So I'm going to be changing my approach and scrapping the gettext api
in favour of PHP arrays and writing a tool for translators to use to
ensure I get valid PHP arrays back from them.
Details of my investigation (which was simple) can be found here:
http://www.inanger.com/languages/php/internationalisation/Cheers,
Mike