The How To Use Loco Translate With MyListing guide will show you how to easily change the text associated with the theme and associated plugins.
As a US-based company any changes we make within this guide reference the English language.
Translate the MyListing Theme
While we recommend using the MyListing Child Theme regardless, Loco Translate works directly with the parent theme, and translations are retained as long as the correct settings are chosen.
- Browse to Loco Translate > Themes
- Select My Listing
- New language
- Choose a language > English (United States)
- Choose a location > Leave it at the default setting of Custom (/languages/loco/themes/). (Note: Do not choose the ‘Author’ or ‘System’ option, as that will allow your translations to be overwritten with future updates to the theme.)
- Click Start translating
- Click the Sync button to ensure you have the most recent data (“strings”)
- In the Filter translations box, enter the text you wish to change (ex. “Choose a Package”), and choose the exact match from the Source text section
- With the Source text selected, enter the new text you would like to see (ex. Choose Listing Package), in the English (United States) translation section
Can the Translations Be Kept After Removing the Loco Translate Plugin?
The short answer is yes, as deactivating or even uninstalling the plugin will not delete any translation files.
However, when you store translation files the correct way, as outlined above, this requires the plugin stay enabled.
So if you plan to remove Loco Translate from the picture, make sure you save (or relocate) all your translations using either the ‘Author’ or ‘System’ option, and note the risk in doing so.
Geeky Notes From the Field
Prior to the Loco Translate plugin is installed, the /wp-content and /wp-content/themes folders of your WordPress installation do not contain a languages folder, however, the /wp-content/themes/my-listing folder does contain a languages folder.
The language folder that comes with a default MyListing installation (/wp-content/themes/my-listing) contains my-listing.mo and my-listing.pot files, as well as translations for Portuguese Portugal (pt_PT.mo and pt_PT.po), Portuguese Brazil (pt_BR.mo and pt_BR.po), Russian, and German.
If Portuguese Portugal, Portuguese Brazil, Russian or German are of no importance to your website, you can safely delete them from the Loco Translate plugin or via FTP.
If you followed the steps in the previous section, in their entirety, a languages folder is created at the root of the /wp-content folder, and the path that you’ll then focus on is the /wp-content/languages/themes.
In that folder path, you should have the my-listing-en_US.mo and my-listing-en_US.po files.
After you save your first “translation”, the original my-listing-en_US.po file will be backed up and have “-backup” appended to the filename.
The new my-listing-en_US.po file will contain your “translations”, while the associated my-listing-en_US.mo file will be what WordPress actually reads, for your “translations”.
- Loco Translate > Plugins.
- Select the plugin you wish to translate.
- Follow the same steps as when translating the MyListing theme