FLEX plugin

Compatible with DokuWiki

2009-12-25+ 'Lemming'

plugin Flexible multiLanguage EXtention DokuWiki Plugin

Last updated on
2010-02-15
Provides
Syntax, Helper, Admin, Action

Similar to multilingual, translation, translation2

Tagged with language

This plugin shows a list of available translations for a page. Other than the translation plugin no separate namespaces are needed to store translations.

Download and Installation

  • Download and install the plugin using the Plugin Manager using the URL given above. Refer to Plugins on how to install plugins manually.
  • Configure it through the FLEX setup page in the admin tools.
  • Add the following code in the template page main.php
 <?php
   $flex = &plugin_load('helper','flex');
   if (isset($flex)) echo $flex->showTranslations();
 ?>

Note: Add this piece of code neither at the top nor at the bottom of main.php but instead in-between where it makes the best optical impression. If you have several themes or skins installed you need to add this piece of code into each main.php to allow the FLEX plugin for every skin.

Syntax and Usage

1 Using the FLEX-Tag

{{flex>lc_1=pageid_1&lc_2=pageid_2& ....}}
lc_i language code
pageid_i a pageid, namespace including relative can be used as well

Example:

{{flex>en=the_fifth_element&de=das_fuenfte_element&fr=le_cinquieme_element}}

2 Select the Interface Language by Patterns

Set up the interface language for specific pageid patterns by using the FLEX setup page in the admin tools.

Use the following format:

regexp   languagecode

Examples

-de$ de
(start|index) en
^klingon tlh

Note: If there is no match, the interface language will be set to the browsers favorite language or if not possible, to the default value.

plugin/flex.txt · Last modified: 2010/02/22 19:43 by 74.93.99.97
 
Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 3.0 Unported
Imprint Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki
WikiForumIRCBugsGitXRefTranslate