Motors - Car Dealership & Classified Listings Mobile App for Android & iOS

  • Home
  • WordPress
  • How to translate or change strings of the the...

How to translate or change strings of the theme and plugins?

This article describes how to localize the themes and plugins using several methods and change the default strings without changing the site language.

You can change your site main language via Settings -> General -> Site Language.Theme and plugin language files are located in a ../wp-content/themes/theme-folder/languages/ and ../wp-content/plugins/plugin-folder/languages/ folders respectively. 

There are two ways to fill up translations:

Using Loco Translate plugin 

The easiest way of translating the theme is by using the Loco Translate plugin. After installing this plugin the Loco Translate menu appears in your dashboard menu. You need to go to Loco Translate -> Themes and select the theme which is active in your WordPress. 

Most of our themes are contain ready translation files in multiple languages. If there isn't a needed language, then you can create a language file by clicking on the New Language link. 

In this section, you need to select the language and set the location to the System folder. You choose the same language which you set in the WordPress Settings -> General.

After, click on the Start translating button. It will create a translation file and redirects to the Loco Translate editor where you can start translating the theme strings. 


The process of translating plugins is the same. You should just go to the Loco Translate -> Plugins section and select the needed plugin.   

In order to keep your translations during theme updates, we recommend to save them in ../wp-content/languages/themes/ and../wp-content/languages/plugins/ folders respectively.


Using the PoEdit platform

Besides the Loco Translate plugin, you can use a PoEdit platform. You can add translation via editing your .po file and at the end, PoEdit generates .mo file for you. Then you can upload ready translation files to primordial folder (../wp-content/themes/theme-folder/languages/). Before adding translations for static strings it needs to rename language files correctly according to your site languages. You can find a list of language codes at WordPress in your Language. As an example, the language code for English is en_EN, so you would save the translated files as en_EN.po first, then


Changing Static Strings

There are some static strings, which come with theme and plugin templates. For example: read moreLoginRegisterlearn more etc. The best way to change these strings would be through the translation files. To change any theme generated text, you can use the same process described above.

You can add translations even for your default (ex: English) site language.  

The screenshot above displays that "cars" string of the theme can be changed to "bikes" in the same language. After saving changes, you will be able to review the changes on the website. 

As you can see, "cars" string has been replaced with "bikes" string on the frontend. You can change the theme and plugin strings by using the same actions.   





Was this article helpful?

Yes No

Thanks so much for your feedback!

Thanks so much for your suggestion!