From phpLDAPadmin

Jump to: navigation, search


Translating PLA

phpLDAPadmin now uses gettext for all its translations - it has been using gettext since 0.9.8.

Under /locale/ in your PLA home directory, you will see many subdirectories, each with a:

  • .po file - which contains the gettext message ID, and its translation for that locale, for example, _('Hello'), and
  • a binary .mo file, which is the compiled gettext translation file

Updating the Translations

phpLDAPadmin is now using Launchpad to manage the translations.

By using Launchpad, it means that many people can update the translations at the same time, after which you can download the resulting mo and/or po file and immediately start to use it. You may even find that your language has been updated since PLA was released.

NOTE: It would be great if somebody could become our Language Expert and optimise the language submission procedures (and documenting them on this wiki), so that it becomes easier for all users. If you know Launchpad well, or you would just like to help out, please contact one of the developers.

Uploading Translations

Launchpad allows you to upload your translated file, after you have been working on it offline. IE: You dont have to use their web interface.

If you want to use your favourite tool to translate PLA, then first download your language po file from Launchpad, edit it with your favourite tool, and then upload the result.

Some tools that you can use for editing .po files include:

Some guidelines

  • Make sure your .po file is encoded with UTF8.
  • Dont put any HTML in your translation (we want to remove all HTML in the LANG files)

Using the Translations

Just changing the variable

 $config->custom->appearance['language'] = 'es_ES';

Will probably not suffice. You need that your underlying OS also has the correct locale. If you use Debian for example and you want to use the es_ES translation as per the example above, you will also need to build the es_ES.UTF-8 locale regardless of which locale you choose as your default for the OS. Simply:

 dpkg-reconfigure locales

And make sure you select es_ES.UTF-8 from the list, and after that you will be prompted to select which is the default locale of your system. It need not be the locale of PLA.

Personal tools