Think multilingual!

Zikula supports multiple languages by defines for each languages. This system offers a full translatability in each language if you use it correctly, but also can result in nearly unusable gibberish.
One of the biggest Donots is the splitting of a sentence in multible defines.
While in English there is no problem in using _NEW and _ARTICLE for "New article" in German it'll be grammatically wrong since the adjective is adjusted to the noun's gender.

Thus one of the most important rules in using multi language defines is:
Always define the full sentences!

You can also use placeholders like %name% in your langdefines:

Code

  1. define('_FOO_NEWMAIL', 'You\'ve got a new mail from %name%!');


In Smarty you can use it by:

Code

  1. <!--[pnml name="_FOO_NEWMAIL" name=$from.name]-->


In PHP:

Code

  1. pnML("_FOO_NEWMAIL", array('name' =&gt; $from['name']));


By this way even language with different syntax can display correct sentences!

Share This

Trackbacks

(The URL to TrackBack this entry is: TrackBack/main/id/26,1-14). If your blog does not support Trackbacks you can manually add your trackback by using this form.

Comments

Add a new Comment









 
Close

You don't have permission to e-mail this story - please login