Extension:I18nTags

From MediaWiki.org

Jump to: navigation, search

         

Manual on MediaWiki Extensions
List of MediaWiki Extensions
Crystal Clear action run.png
I18nTags

Release status: stable

Implementation  Tag, Parser functions
Description Access the i18n functions for number formatting, grammar and plural in any available language
Author(s)  Niklas Laxström (NikerabbitTalk)
License No license specified
Download Download snapshot

Subversion [Help]
Browse source code

Example  translatewiki.net

check usage (experimental)

The i18nTags extension provides access to i18n functions for number formatting, grammar and plural in any available language.

[edit] Installation

  1. Download the latest snapshot and extract it to your extensions directory.
  2. Add
    require_once( "$IP/extensions/I18nTags/I18nTags.php" );
    to LocalSettings.php
  3. The extension should be now active.

Optional: install the cldr extension to get languages names in any language.

[edit] Features

{{#languagename:}}
Get the language's name in user language.
<formatnum>
Like {{#formatnum:}} but for any language. To choose the language, use <formatnum lang="..."></formatnum>.
<grammar>
Like {{#grammar:}} but for any language. To choose the language, use <grammar lang="..."></grammar>.
<plural>
Like {{#plural:}} but for any language. To choose the language, use <plural lang="..."></plural>.
<linktrail>
Emulates the linktrail for a specfic language.