Documentation
In this documentation, you will find all the important information about the plugin – from installation and configuration to usage and extension.
Multilingual Support
In this post, we’ll walk you through:
Cevento supports multilingual functionality, allowing you to provide the user interface and content in multiple languages.
This is achieved through translation files (.po and .mo) that contain all plugin texts.
As is common in WordPress, these translations can be customized or extended in an update-safe way.
Requirements
To edit existing translations or add new ones, gettext must be installed on your system.
With the included msgfmt tool, edited .po files can be compiled into .mo files, which WordPress will then use.
Alternatively, you can use a tool like Poedit to edit .po files and export the compiled .mo files.
Adjusting Existing Translations
- Locate the
.pofile of the desired language in the directory[plugin_root]/languages/. - Copy this file into the following WordPress language directory:
[wp_root]/wp-content/languages/plugins/ - Apply your changes to the copied
.pofile. -
Generate the
.mofile withmsgfmt, e.g. for German (de_DE):msgfmt -o cevento-de_DE.mo cevento-de_DE.po
Adding a New Language
- Copy the file
[plugin_root]/languages/cevento.poand rename it accordingly:cevento-[locale_code].po.
You can find all locale codes in this list. - Move the file into the following directory:
[wp_root]/wp-content/languages/plugins/ - Enter all required translations into the
.pofile. -
Compile it into a
.mofile usingmsgfmt:msgfmt -o cevento-[locale_code].mo cevento-[locale_code].po