Several add-on packs have been updated today with the Swedish language translation thanks to Piani Sweden AB. The updates are available now to any users that has purchased the add-ons.
The 4.2.01 release of Contact Extender for Store Locator Plus was published today with the latest Dutch translation included thanks to DeBAAT. In addition to the new Dutch language files, Contact Extender has been upgraded to use the Store Locator Plus 4.2 add-on framework. This makes for a smaller footprint and faster performance when using Contact Extender.
This version of the add-on pack requires you have upgraded Store Locator Plus to version 4.2.03 or higher.
Contact Extender Production Release Details
Contact Extender 4.1.02 is now available for download. This version fixes the field names for all Contact Extender data columns.
If you had installed the interim 4.1.01 release with translated field named and modified you search queries, headers for location import/export, or order by queries and are not using English as the default language for WordPress you will need to revise your installation when upgrading to this release.
Most users will not be impacted by this update.
Enhanced Results version 4.1.09 has passed testing and is now available for download.
This version fixes the field names for the extended data RANK and FEATURED data columns. If you have modified you search queries, headers for location import/export, or order by queries and are not using English as the default language for WordPress you will need to revise your installation when upgrading to this release.
Prior releases that were running with translations in place for “Featured” or “Rank” were creating the field names in the extended data table with the translated string as the actual field name. This was causing problems with the built-in Enhanced Results order-by clause and having other side effects. With the 4.1.09 patch the field names will remain in their native English format while the displayed text on the user interface and admin interface will be the translated string.
Store Locator Plus 3.11.13 was released today. It is the simplest release I’ve done in the past year since taking over the plugin development. This release adds the Dutch translation files to the base product. The language code is nl_NL.
Thank you Jan de Baat for your contribution!
That’s it. Back to the custom code updates and 4.0 work.
Some of my plugins use settings in the main application settings page to set labels on the user interface. However, MOST of the admin interface instructions and labels and some of the labels on the user interface can only be changed by using the WordPress language translation system.
To create a translation file you will need to download the latest .pot file for the plugin that you wish to translate, then create a .po file from it. The easiest way to start is simply copy the .pot file to a new <locale>.po file, such as da_DK.po.
All of my plugins have a languages subdirectory that contains the .POT and some .PO files that have already been translated.
After the strings are marked in the source files, a gettext utility called xgettext is used to extract the original strings and to build a template translation POT file. Here is an example POT file entry:
#: wp-admin/admin-header.php:49 msgid "Sign Out" msgstr ""
Every translator takes the WordPress POT file and translates the msgstr sections in their own language. The result is a PO file with in the same format as a POT, but with translations and some specific headers.
Naming The PO and MO Files
The .po and .mo files should follow the standard naming convention which is:
<text_domain>-<language code>_<country code>.<po|mo>
For Store Locator Plus, the text domain is csa-slplus. You can see this in the top of the store-locator-le.php file as part of the comment, however not all plugins will have that helpful hint. You should look for the load_plugin_textdomain function call within the plugin to find the true identity of text_domain. This is on line 241 in the storelocatorplus-actions_class.php file (for Store Locator Plus version 3.11) which reads load_plugin_textdomain(‘csa-slplus’,false, SLPLUS_PLUGINDIR.’languages/’);
The language code is one of the pre-defined language codes as defined by PHP. This is typically a lowercase pair of letters such as “en” for English or “es” for Spanish.
The country code is one of the pre-defined 2-letter country codes. For example, US for USA, GB for United Kingdom, for Canada.
The combination of language plus country code allows for nuances in the language that my vary by specific location.
Thus, for an American translation the file name for Store Locator Plus would be csa-slplus-en_US.po and csa-slplus-en_US.mo. For The United Kingdom it would be csa-slplus-en_GB.po and csa-slplus-en_GB.mo.
Using Codestyling Localization Plugin
I recommend using the Codestyling Localization plugin to make it far easier to create the related PO files. This plugin reads the plugin directory and provides a web based interface for creating translations.
Send Your Translation
If you create a .po translation file, please send it to us at info_at_charlestonsw_dot_com or post it in the forums. Tell me which plugin or add-on pack and which version of the plugin you created it for, and I will include it in the next public release.
Also, if you send a complete translation file, I’ll grant access to the premium add-on packs for your account!