How to Translate a module?

saison - February 11, 2008 - 13:14

Hello,

I work with the JOB SEARCH module and I found a Russian translation of it, which consists of a simple document.
It does not seem very difficult to make the same for french, and I would like to do so, and share it with the community afterwards .
Is there a specific way/module/software to translate drupal's modules? How do I have to do?
thanks a lot.

A few steps

hsalazar - February 11, 2008 - 14:21

saison:

  1. Download and install the Translation Template Extractor (POTX).
  2. Use POTX to extract from the installed module a .pot template, that is, a file that includes the untranslated strings in english.
  3. Download and install POEdit, the most common string translator.
  4. Use POEdit to create, from the extracted .pot template, the French version of the strings, a file with the .po extension.
  5. Use the locale module to import the new .po file so that the module's interface appears in french.

Done!

resolved

saison - February 11, 2008 - 15:51

Thank you so much, it is very clear.

Short and direct, worked

rmanola - February 11, 2008 - 16:05

Short and direct, worked fine for me, thanks!

Great info!

nastov - May 24, 2008 - 21:50

Thank you sooooo much!
In the past, I've used different types of translation for a PHP portal, and it was always painstaking.
This is so fast and easy that I translated the entire contact module within 10 minutes =)
I just love Drupal =)

Steps to Translate a Module

coupet - May 24, 2008 - 23:01

Add an entry in Documentation

----
Darly

Steps 6, 7 and 8

fl3a - October 18, 2009 - 10:49

If you want to provide the translation of your module to the community, you should go on further with these steps, assuming module is called example and you are using 6.x.

  1. Create a translations within your the folder of your module, e.g. example/translations
  2. As a base for other translations, place the .pot file (example.pot) which you created in step 2. above within the translations folder. example/translations/example.pot
  3. Place the extracted .po from step 4. there as e.g. ru.po for a russian translation, too. example/translations/ru.po

Notes: If you use 5.x, the folder created in step 6 should be example/po.

 
 

Drupal is a registered trademark of Dries Buytaert.