You are here: HomeOther ExtensionsSmart CountdownLocalization Plugin

Localization Plugin

1 User Rating:  / 1
PoorBest 

Localization plugin included in the package is optional. Smart Countdown module can function perfectly without this plugin installed.

Still, once enabled, it will help users to configure Smart Countdown for multilingual sites.

When you publish a module to a multilingual site and this module contains user-defined text that should be translated to site's active language, normal approach is to create one copy of the module for each installed language. Each copy can have its own configuration so that all text fields that need translation may be entered in the language the particular module's copy is intended for.

Without the localization plugin for Smart Countdown this is the only way you can implement it in a multilingual site. As of the fact that event title is always a user-defined piece of text it is impossible to use language files (the use of language .ini files is limited to standard text strings, such as field names in options or time labels - e.g. days, hours, etc.).

In case of Smart Countdown this approach has significant drawbacks. It is logical that all language copies of your module will share the same layout settings and the same event date and time. As for the settings, it is not a big problem - just configure each copy once and you're OK. But what if you need to modify the event date and time? You will have to enter the new date for each copy of the module! The same will happen when changing layout or style.

The localization plugin makes it possible to have only one copy of the counter module keeping all your settings in one place. Fields for event text translations for all installed languages are added automatically to the module's edit form. In the image below, that corresponds to the module edit screen with localization plugin installed you see 2 new fieldsets (the site that this screenshot was taken from had 2 languages installed).

strings

You can enter appropriate text (or html code - the same manner as for basic options texts) for each language (in this sample English - UK is open ready to recieve user input). This text will be displayed when active language for the page is en-GB. If no text is found in localized strings for current site language the module will display the text set in Basic options (uni-language text - see above).

All other module settings remain intact. So you have all settings on the same edit screen and any option modification will have immediate effect on the module's appearance for all languages.

SmartCalc is published on JED
5 5 5 5
5 5 5 5
2 2 2 2
Days
0 0 0 0
1 1 1 1
Hour
5 5 5 5
7 7 7 7
Minutes
5 5 5 5
9 9 9 9
Seconds