- Poedit translate wordpress theme how to#
- Poedit translate wordpress theme mac os x#
- Poedit translate wordpress theme pro#
- Poedit translate wordpress theme software#
GNU gettext – The framework has its own set of command-line tools to produce the POT file and to compile the MO file.
Poedit translate wordpress theme mac os x#
Poedit translate wordpress theme how to#
There are many available options here and this guide will show you how to use two Open Source tools:
Poedit translate wordpress theme software#
Special software tools are needed in the translation process. Compile the PO file to produce a MO file (Machine Object), which can then be used in the theme or plugin.The only difference between a POT and PO file is that the PO file contains translations This produces a PO file (Portable Object). Use a plain text editor or a special localization tool to generate a translation for each piece of text.Some themes and plugins may already provide you with this Run a tool over the code to produce a POT file (Portable Object Template), simply a list of all localizable text.With a suitably localized theme, plugin, or WordPress, the steps involved in translating it are: If number is more than 1 then looks for a translated version of $plural. _ngettext($single,$plural,$number) – If $number is 1 then looks for a translated version of $single._e($text) – Looks for a translated version of $text and echo the result to the screen (i.e._($text) – Looks for a translated version of $text and returns the result.It is not important to know how these functions work, but it will be helpful to recognize them: Text is marked by wrapping it with special PHP functions. No code needs to change and you do not need to understand how the program works. The role of the translator is to take these marked pieces of text and produce a language-specific localization. This framework provides the programmer the ability to mark text inside code as being suitable for localization.
WordPress uses a standard localization framework called GNU gettext. If you are a plugin or theme writer then please take a look at Preparing A Theme Or Plugin for Localization, another in the Inside WordPress series that is specifically targeted at the steps involved before a translation can occur. Detailed explanations will be given at every stage and you are invited to provide feedback or pose questions.
The guide will be written from a beginners perspective and will not assume any knowledge of PHP or HTML (although some will be helpful). Even if you have little PHP or HTML skills you can still contribute to making WordPress a truly international experience by providing localizations for existing themes and plugins.
The phrases you translated will now be added to the translation page for the plugin your working on.This guide is another in the Inside WordPress series and attempts to show how to produce a translation for an already-prepared theme, plugin, or WordPress itself. When you have finished save the file and import it back into the same page you downloaded it from. Look at the options and click the one you feel is closest, adjust it as needed or write a new translation. The file opens and one will see the English (US) words on the left and suggested language translation on the right. It will open a browse for file dialog box. I left it at default and clicked the Export link to download a po/pot translation file.Ĭlick the first option. Select a project for instance Development (trunk).Īt the bottom of the “Translation of Development (trunk)” page you will see the options for Import Translations Export and then drop downs showing the default “all current” as “Portable Object Message Catalog (.po/.pot)”. locale/nb/default/wp-plugins/all-in-one-seo-pack The translation plugin page for All in One SEO. I help translate the plugin into Norwegian. Poedit will suggest translations for each phrase. I will use the plugin All in One SEO as an example. I have earlier used Poedit 1 and recently upgraded to version 2 Pro.
Poedit translate wordpress theme pro#
Translating a WordPress theme or plugin using Poedit 2 Pro