Module:Lang-zh/doc

MyWikiBiz, Author Your Legacy — Tuesday October 01, 2024
< Module:Lang-zh
Revision as of 23:29, 15 July 2021 by Zoran (talk | contribs) (Pywikibot 6.4.0)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

This is the documentation page for Module:Lang-zh

Template:Module rating Template:Lua

Usage

This is the module for the template {{Lang-zh}}. Its main features are described on that template's documentation page, refer to that for how to use it in articles. This documentation describes some particular features of the module.

The first table in the module lists the articles in which the template will put traditional Chinese first. Add articles to this list in the same fashion (the order doesn't matter) to include them. If you cannot edit the module because its protected use the {{edit template-protected}} template on its talk page to request a change.

Use from other modules

The module can be called directly from another module as well as a template. To do this first load the module

<syntaxhighlight lang="lua"> local Zh = require("Module:Lang-zh")._Zh </syntaxhighlight>

Then call it as follows, with the arguments in a table

<syntaxhighlight lang="lua"> local output = Zh{["c"] = "中国", ["p"] = "zhōngguó"} </syntaxhighlight>

Tracking categories