Hub Elementor - Translating the Theme

In this section, you will find the information you need to translate the Hub theme into your language and use it in multi languages. It is separated into different subsections to help you quickly find what you demand. The Hub theme and the Hub Core plugin are translated separately. Initially, let's take a look at Hub.

IMPORTANT NOTE: To fully translate your website, please remember to translate the Hub Core plugin as well as Hub theme. Discover our articles about Translating Hub Core.

With the translation files; frontend, theme options, and page options can be translated:

Frontend: Everything you see while navigating your website, such as; contact forms, blog strings (about the author, related projects, etc.), portfolio strings


Hub Theme Options: All the theme options; General options, header options, footer options etc


Theme Translation Basics

This section will explain where you can find the files needed for translation and what these files are for. 
hub.pot - A list of all the text strings used in the Theme files. These text strings are in the English language and can contain a translation for each text string. This file can be used as a starting point to create your own translations, using e.g. a third party tool like POEdit. 
The source file hub.pot can be found inside the hub > languages. Please see the screenshot.

The Translation Process

Create a new .po file from the hub.pot located in the languages folder, translate all text strings, then save the .po file with your language code and make sure the corresponding .mo is created, which can be read by WordPress. The next subsection will explain this in detail. If you only want to change a string in an included hub.pot file, the same steps apply. Or you can use the Loco translate plugin
Either you are setting up an entirely new language file, or you just want to edit hub.pot language files, the steps to take are simple and more or less the same.
The language files can also be used if you only want to translate a small portion of the theme or one specific area. You do not have to translate the entire theme, you can choose what you want to change inside the hub.pot file. This is the preferred method for translation.

How To Edit The .po file With 3rd Party Software

There are different editors out there for the purpose of editing .po and .pot files, but POEdit is easy to use, it is available for all platforms, and it is freeware. To download POEdit, follow this  link.

How To Start A New Language From Scratch

Step 1 - Open the hub.pot in POEdit by selecting 'New from POT/PO file...'. Once it has loaded, you will find all English text strings in the left column called Source Text. Once you add translations, they will show up in the right column under Translation.
Step 2 - Choose the line you want to translate. In the lower right section of the POEdit window, you will find a text area where you can add the correct translation.
Step 3 - When you are done translating all the needed text strings into your desired language, save the file with the theme name and your language code. For example, if you were translating to the Deutsch language, you would save it as de_DE.po. The corresponding .mo file will be auto-created.

After choosing the language, you can start translating straight away.