Purpose of the Plugin
This plugin allows you to create a customized translation of the terms that a plugin (or theme) uses for your users.
Not all plugins are translated in all languages and those that are translated will (presumably) work in another language when you set so the installations language (i.e.: from WordPress settings).
But what if you need to have your site’s language set to English and at the same time some functions of a plugin set to another language?
In that case you need to translate only those terms.
I used it to
translate terms of the BuddyPress plugin for logging-in and registering.
Before you use the plugin
you need to:
- find the plugin’s POT file. In the case of:
- BuddyPress it is in: \wp-content\plugins\buddypress
- for Namaste! LMS in: \wp-content\plugins\namaste-lms
- for WATU: \wp-content\plugins\watu
- and save it as PO (i.e.: same name but with an .MO ending instead of the .POT), at first locally (in the your hard disk) in order to create the translations in the terms you need using
- POED. This will take some time because often these files are very long. Then
- you produce the .PO and .MO files and save the former
- in the \wp-content\languages directory of your installation (if it doesn’t exist, create it).
Using it – Step by Step
- Select the plugin (or other) for which you will use custom translations (it will later reflect in (a)).
- Select the language for which you are creating a custom translation (it will later reflect in (b)).
- Choose the MO file (from your hard disk, it was produced by POED and stored in the same place with the PO file). This will reflect in (c).
- Click the “Add new rule” to create the rule. That will be a rule that (in other words) this plugin (a) will be using these translations (c) when the site language is set to (b).
If you don’t see the results immediately it could be because of some cache. When I first did that I saw the results in my browser after 2 days.
File types involved
- POT (Portable Object Template) is a template file that a plugin (or theme) uses to mark the “objects” (the terms) that it uses and are translatable.
- PO (Portable Object) is the file with the terms of this plugin translated in another language, and
- MO (Machine Object) is the machine language translation of the MO file
Other applications needed or used
I used POED (a free application) very practical to Edit PO files and produce the corresponding MO files.
Other Plugins that do the same thing
the list that follows is NOT exhaustive. Only includes plugins that I tried.
- Loco Translate , the procedure appears to be more automated but for what I needed to do I’m not sure it could do it. On the other hand it can do a lot more than handling a custom MO file.