Ionize User Guide Version 0.9.6


Language Tags

translation

Returns :

  1. the static term translation, for the current language.
  2. or #your_term if the translation isn't found.
<ion:translation item="your_term" />
Attribute Optional Values
item no The index name of the translated term, as displayed in the Content > Translation panel of Ionize.

languages

Iterator for languages.

Commonly used to display the languages navigation menu.

<!-- Code -->
<ion:languages tag="ul" class="langs" id="my_langs" active_class="active" />

<-- HTML Result on the "About" page with 2 languages : "English" as default language and "Français" --> 
<ul id="my_langs" class="langs" active_class="current" >

    <li class="curent"><a href="http://my_domain/en/about">English</a></li>
    <li><a href="http://my_domain/fr/a-propos">French</a></li>

</ul>
Attribute Optional Values
active_class yes Will output this class for the current displayed language content.
tag yes Puts the results into the given tag
id yes Adds the HTML id attribute to the produced tag.
class yes Adds the HTML class attribute to the produced tag.
helper yes <Name of the helper>:<function> to use to display the language menu.
This is another way to implement your own helper to display the language navigation.
If your helper file is called my_language_menu.php and your helper function is named my_language_func(), you will write : <ion:languages helper="my_language_menu:my_language_func" />
no_helper yes true / false. Default to false.
Forces the tag to not use the helper.
In this case, the children tags must be used.

Children tags

These children tags can only be used only if the attribute "no_helper" is set.

Tag Returns
<ion:code /> Lang code, as set in Ionize.
<ion:name /> Lang name, as set in Ionize.
<ion:url /> Complete URL to the current content in the looped language.