Template:Translation: Difference between revisions
From Heroes of Might and Magic: Olden Era Official Wiki
No edit summary |
No edit summary |
||
| Line 5: | Line 5: | ||
| where = | | where = | ||
T.target_id = "{{{1}}}" | T.target_id = "{{{1}}}" | ||
AND T.language = "en" | AND T.language = "{{{2|en}}}" | ||
| fields = | | fields = | ||
T.name | T.name | ||
| Line 11: | Line 11: | ||
1 | 1 | ||
| default = | | default = | ||
— | |||
| more results text = | | more results text = | ||
| Line 34: | Line 34: | ||
2. Japanese | 2. Japanese | ||
{{Color|yellow|Input:}} <code><nowiki>{{Translation | nature | ja}}</nowiki></code> | {{Color|yellow|Input:}} <code><nowiki>{{Translation|nature|ja}}</nowiki></code> | ||
{{Color|lime|Output:}} {{Translation | nature | ja}} | {{Color|lime|Output:}} {{Translation|nature|ja}} | ||
</noinclude> | </noinclude> | ||
Revision as of 14:35, 14 July 2026
Retrieves the name value from the Translation Cargo table for a target id, in the desired language.
This is very similar to the Label template, but is more generic, allowing you to pull any id
from the Translation table, not just those prefixed with wiki_.
Usage
1. English
Input: {{Translation|nature|en}}
Output: Grove
2. Japanese
Input: {{Translation|nature|ja}}
Output: グローヴ


