< All updates | May 24, 2024

A practical guide to WordPress String Translations

If you have a good plugin or theme, there are fixed texts included in the code that should be able to be multilingual. This is also called theme or plugin localization. Translating your WordPress site is essential to reach a wider audience. I am here to make that process simple and efficient. The reason why I’m unique, is my user-friendly interface and simple search mechanism. This makes me an excellent alternative to other translation plugins such as WPML, Polylang and MultilingualPress.

What are WordPress String Translations?

String translations in WordPress refer to the translation of text strings embedded in the code of themes and plugins. These can be texts displayed on the front-end or in the admin area of the site. Think buttons, error messages, labels, menu items and other text that the user sees and needs to understand. Below you can see the text as it appears in my plugin. The base language of WordPress is English and the ‘group’ of translations belongs to the ‘wpmula’ plugin.

String vertaling voorbeeld

This kind of text is ‘fixed’ in the code, just like the ‘Add to cart’ or ‘Place order’ buttons or various notifications in WooCommerce.

By default, the translations of these types of ‘strings’ are stored in a ‘.po’ and ‘.mo’ file (belong together). These are ‘static’ files that are then read back in by WordPress and used for translation. Each language has its own set of ‘.po’ and ‘.mo’ files. As an example, these are the .po/.mo files for me.

PO en MO bestanden voorbeeld

Why are string translations important?

Translating your site ensures that your content is accessible to a wider audience. Whether you run an international business or offer a local service…, Multilingual Support helps you to:

Expand reach: appeal to a wider audience by making your site available in multiple languages.

Improve user experience: ensures that visitors understand the content and feel more engaged.

Increase conversions: reduces barriers for visitors, which can lead to higher conversions and customer satisfaction.

How is it different from other plugins?

Now that you understand why string translations are important. Let me show you how I simplify and optimize this process. I am of course assuming here that you have purchased, installed and activated me in your WordPress site. Translating a ‘String’ in WordPress can be done via a simple way, namely via a search function.

Loco Tanslate beheer menu voorbeeld

The classic way (as Loco Translate does, for example) is an overview of all plugins, themes with all corresponding translations. Basically there is nothing wrong with that, because you can work in a very structured way. However, where is the text you want to translate in the code of your site? Is it from WooCommerce, for example, or is it in your theme? Finding the right location can sometimes be quite a hassle.

With Loco Translate, you also have to be careful not to work in “existing” translation files (existing .po or .mo). By doing so, you modify the translation files of a plugin or theme itself, which means that the modifications will be lost in an update.

With a new version, the files of a plugin or theme are completely replaced. Poof, your “string” translations are gone and with that, a lot of time is lost. I work in a different way because I save the translations in a different place. This way, you won’t ‘lose’ your translations due to an update, and you can work safely. 😀

So with the classic approach, you have to browse through all plugins/themes for the right ‘string’ (and pay close attention to what you are doing). With me this works the other way around, because you can easily search for the ‘string’ via a search field and then translate it directly. Sounds convenient and it is 🙂

Getting started with me, Mula 🙂

Login to WordPress and go to the dashboard. Then go to the ‘String translations’ under the wpMula settings. On this page can find a search form, which allows you to translate the ‘string’ you are looking for at lightning speed. The ‘search engine’ searches all the ‘.po’ and ‘.mo’ files there are in your WordPress website. You can search in the ‘source’ language (WordPress defaults to English) or in the ‘target’ language. The language you are going to translate can be determined via the ‘Language’ dropdown. Here you can also translate the existing ‘English’ texts, should you want to change anything in them.

wpMula beheer menuString vertalen formulier

 

 

 

 

 

Suppose you want to change the ‘out of stock’ message in your shopping cart on your webshop…. In this case, you search for ‘out of stock’ and see the following result. The ‘Custom translation’ is already filled in with the ‘Default translation’ to give you a quick start.

String vertalingen zoeken

Then you customize the sentence to your liking and click save custom translation. The translation is then saved and applied.

String vertalingen opslaan

If you want to remove your custom translation, you can easily do so from the list of existing translations. Look in the list and click ‘Remove translation’ to remove your translation.

String vertalingen verwijderen

Want to know more about how this works? Then check out the manual for a detailed explanation.

Just use me to make your site multilingual 🙂

I make translating your WordPress site simple and efficient. With my user-friendly interface and powerful search function, you can quickly and easily translate strings and make your site accessible to an international audience. Plus, my secure storage ensures that your translations are preserved even after updates. Start using it today and experience how easy translation can be!