How to Translate our Plugins Using the CodeStyling Localization Plugin

Here is a step by step guide to help you translate the WP Rich Snippets plugin using the CodeStyling Localization Plugin that can be downloaded from WordPress.org website.

1- Install the CodeStyling Localization Plugin

The CodeStyling Localization is a free plugin that can be download it from here (you also can install it directly within your WordPress dashboard), start with downloading/installing the plugin on your WordPress website, then head to the Localization page under the Tools menu.

2- Add New Language

Click on the Add New Language button as showing below:

localization add new language

3- Choose Language

A window will pop up, choose your Language from the list, and click on the Create po-file button as shown below:

localization choose new language

4- Click on the Edit button

Now, click on the Edit button.

localization new language po-file

5- Start translating to your own Language.

A new page will open and you will see all wording that you can translate to your own Language.

localization translate language file

6- Translate & Save

Now it’s all about translating every word and save the translation.

localization star translating

 7 – Generate mo-file

Once you are done with the translating , click on the generate mo-file button and make sure you select Textdomain: “wprs”.

localization generate mo file

8- Check via FTP

Make sure that you’ve got two files in the languages folder that is located at:

wp-content/plugins/wp-rich-snippets/lib/languages  folder.

localization language files

9- Check your wp-config.php file

Make sure you are have this line in your wp-config.php file with the exact Language of the file name, example:

define ('WPLANG', 'ar_EG');

If you have a different name set on that line above, then make sure to edit the files name to match it.

10- Backup the translation files

It’s highly recommended that you make backup of the .po and .mo files and save them in a safe place on your computer, so when you upgrade the plugin you can always upload these two files again to the Languages folder. (Let us know if you have created translations so we can add it to the plugin core files).

You are done!