قالب:Translation table
Example:
| English | Spanish |
|---|---|
| hi | hola |
| one | uno |
| two | dos |
| three | tres |
| four | cuatro |
| five | cinco |
| six | seis |
| seven | siete |
| eight | ocho |
| nine | nueve |
| ten | diez |
| goodbye | adiós |
It is recommended to use the source editor when editing using this template.
| Uses Lua: |
Usage
This template renders a two-column translation table using the language codes provided by the user. It supports both named and unnamed (positional) text/translation pairs.
Syntax
{{Translation table
|lang1code=es
|lang2code=en
|hola|hello
|uno|one
|dos|two
}}
You can also use named pairs for the same effect:
{{Translation table
|lang1code=ja
|lang2code=en
|text1=ありがとう |trans1=thank you
|text2=さようなら |trans2=goodbye
}}
Notes
- Uses {{Lang}} under the hood for accessibility (adds lang attribute).
- Accepts italic/bold/link formatting (via `Langx`).
- Automatically derives column headers using {{ISO 639 name}}.
TemplateData
See the monthly error report for this template.
TemplateData for Translation table
Renders a two-column translation table using language codes and the {{Lang}} template for proper internationalization. It is not recommended to use this template while using the visual editor.
| وسيط | وصف | نوع | حالة | |
|---|---|---|---|---|
| Language 1 code | lang1code lang1 | Language code for the first column (e.g. 'es' for Spanish)
| نص | مطلوب |
| Language 2 code | lang2code lang2 | Language code for the second column (e.g. 'en' for English)
| نص | مطلوب |
| Use "wikitext" table class | wikitextclass | Whether or not to set the table class to "wikitext". This will not affect your ability to put wikitext into the table.
| بولياني | اختياري |
| Show Romanization | showromanization | Shows romaji/pinyin/etc.
| بولياني | اختياري |
| Sortable | sortable | If the table should be sortable or not
| بولياني | اختياري |
| First text value | text1 | First source-language word or phrase
| نص | اختياري |
| First translation | trans1 | First translated word or phrase
| نص | اختياري |
| Second text value | text2 | دون وصف | نص | اختياري |
| Second translation | trans2 | دون وصف | نص | اختياري |
| The above documentation is transcluded from قالب:Translation table/doc. (edit | history) Editors can experiment in this template's sandbox (create | mirror) and testcases (create) pages. Please add categories to the /doc subpage. Subpages of this template. |