Template documentationview · edit · history · purge ]
This documentation is transcluded from Template:List/doc.

Generates a list of items, using item separators ("comma") and conjunction ("and") before the last item that are appropriate for a given language.

Usage

{{List |1= }}

Template parameters

ParameterDescriptionDefaultStatus
langlanguage codea valid code (i.e. a valid language tag from BCP 47 or supported by MediaWiki translations), in lowercase (usually a 2-letter code from ISO 639-1, or 3-letter code from ISO 639-3, possibly followed by short hyphen-separated subtags for script){{PAGELANGUAGE}}optional
separatorseparatoran alternate separator to use in lists with at least two items; if the special value "comma" or "," is specified, the separator will be the appropriate comma for the language; if the special value "semicolon" or ";" is specified, the separator will be the appropriate semicolon for the language; if the special value "full stop" or "." is specified, the separator will be the appropriate full stop for the language (including a space after it if needed); if the special value "dot", "·", "bullet", or "•" is specified, the separator will be a bold middle dot (·) after a non-breaking space; otherwise the conjunction specified will be used (it must include the appropriate spaces).commaoptional
conjunctionconjunctionan alternate conjunction to use as the separator before the last item in lists with at least two items ; if the special value "separator" is specified, the conjunction will be replaced by the common separator (possibly modified by the previous parameter) ; otherwise the special values "and" and "or" generate the appropriate conjunction for the language ; otherwise the special values "comma", ",", "semicolon", ";", "full stop", ".", "dot", "·", "bullet" and "•" are handled like for the separator parameter ; otherwise the conjunction specified will be used (it must include the appropriate spaces).andoptional
1item 1text; any empty value is discarded from the generated list.emptyoptional
99item 99text; any empty value is discarded from the generated list; if all items are empty, nothing is generated ; if too many items (empty or not) are passed, an error may be displayed after the first ones.emptyoptional

Additional information

The template is intended to be used in the following namespaces: no namespace specified

The template is intended to be used by the following user groups: no user group specified

Relies on:

Examples

Using the default language
  • "<bdi>{{List|1|2|3}}</bdi>" gives "1, 2 and 3".
  • "<bdi>{{List|1|2|}}</bdi>" gives "1 and 2".
  • "<bdi>{{List|1||}}</bdi>" gives "1".
  • "<bdi>{{List|1||3}}</bdi>" gives "1 and 3".
  • "<bdi>{{List||2|3}}</bdi>" gives "2 and 3".
  • "<bdi>{{List||2|}}</bdi>" gives "2".
  • "<bdi>{{List|||3}}</bdi>" gives "3".
  • "<bdi>{{List|||}}</bdi>" gives "".
Using specific languages
  • "<bdi>{{List|1||3|lang=ar}}</bdi>" gives "1 و 3".
  • "<bdi>{{List|1|2|3|lang=ar}}</bdi>" gives "1، 2 و 3".
  • "<bdi>{{List|1|2|3|lang=bn}}</bdi>" gives "1, 2 ও 3".
  • "<bdi>{{List|1|2|3|lang=he}}</bdi>" gives "1, 2 ו־ 3".
  • "<bdi>{{List|1|2|3|lang=hi}}</bdi>" gives "1, 2 और 3".
  • "<bdi>{{List|1|2|3|lang=hy}}</bdi>" gives "1, 2 և 3".
  • "<bdi>{{List|1|2|3|lang=ja}}</bdi>" gives "1、2 および; 3".
  • "<bdi>{{List|1|2|3|lang=km}}</bdi>" gives "1, 2 និង 3".
  • "<bdi>{{List|1|2|3|lang=ml}}</bdi>" gives "1, 2 ഒപ്പം 3".
  • "<bdi>{{List|1|2|3|lang=mr}}</bdi>" gives "1, 2 आणि 3".
  • "<bdi>{{List|1|2|3|lang=zh}}</bdi>" gives "1、​2 和 3".
Changing the default separators
  • "<bdi>{{List|1|2|3||5|separator=bullet|conjunction=separator}}</bdi>" gives "··· 5".
  • "<bdi>{{List|1|2|3|lang=zh|separator=full stop}}</bdi>" gives "1。2 和 3".
  • "<bdi>{{List|1|2|3|lang=ar|separator=semicolon}}</bdi>" gives "1؛ 2 و 3".
  • "<bdi>{{List|1|2|3|lang=ar|conjunction=separator}}</bdi>" gives "1، 2، 3".
  • "<bdi>{{List|1|2|3|lang=ar|separator=semicolon|conjunction=separator}}</bdi>" gives "1؛ 2؛ 3".
  • "<bdi>{{List|1|2|3|lang=ar|separator=semicolon|conjunction=and}}</bdi>" gives "1؛ 2 و 3".
  • "<bdi>{{List|1|2|3|lang=ar|separator=semicolon|conjunction=or}}</bdi>" gives "1؛ 2 أو 3".