[development] Translatable strings for 1st/2nd/3rd/nth

Jose A. Reyero drupal at reyero.net
Thu May 3 19:58:22 UTC 2007

Yes, I have some suggestion, just I dont know whether for Drupal 6 or
next versions..

We need to expand the downloadable translations from being only .po
files to something that may include also some code, maybe a language
icon, maybe some theme functions.... (language packs)
And there should be something like a callback in locale

function locale(...) {
  if (function_exists("locale_language_$locale")) ...

so we'll be able to customize translations for any language, adding
whatever code we need, using the current static strings translations as
a fallback
... or using some web translation service to provide translations when
there's none available...

So, basically, we need to be able to hook some function calls into all
language related functions. By the way, I think we are heading in that
direction with the -soon to be posted- patch for user string
translations, which is part of the Drupal6/i18n development.

Chris Kennedy wrote:
> Does anyone have suggestions for creating translatable strings for rankings?
> I need to generate strings for 1st/2nd/3rd/4th/etc. ideally without a
> limit, but don't know of a simple translatable solution.
> Right now I just have individual t() strings for 1st/2nd/3rd, then a
> blanket t($i .'th') for the rest, under the untested theory that
> translators could manually add translations for Nth into their .po files
> up to a reasonable limit. I realize that this will not work for
> extractor.php purposes and is English-centric.
> Thoughts?
> Thanks,
> Chris

More information about the development mailing list