Template:Translation category: Difference between revisions

From Modded Wiki
Jump to navigation Jump to search
mNo edit summary
No edit summary
 
(4 intermediate revisions by 3 users not shown)
Line 1: Line 1:
<includeonly>{{ #vardefine: $lang-list | {{ #dplreplace:
<includeonly>
/
[[Category:{{ #if: trim | {{{1}}} }}{{#if:{{{sort|}}}|{{!}}{{{sort|}}}}}]]
|[\n ]}}<!-- trim whitespace to maintain "switch" feel -->
</includeonly>
}}{{ #vardefine: $lang | {{
<noinclude>
  #if: {{ #pos: {{ #var: $lang-list }} | /{{SUBPAGENAME}}/ }}
  | {{SUBPAGENAME}}
  | {{ #if: {{ #pos: {{ #var: $lang-list }} | /{{SUBPAGENAME:{{BASEPAGENAME}}}}/ }}
    | {{SUBPAGENAME:{{BASEPAGENAME}}}}
    }}
  }}
}}{{
#if: {{ #var: $lang }}
| {{ #if: {{{project|}}} || [[Category:{{ #if: trim | {{{1}}} }}/{{ #var: $lang }}{{ #if: {{{sort|}}} | {{!}}{{{sort|}}} }}]] }}
| [[Category:{{ #if: trim | {{{1}}} }}{{#if:{{{sort|}}}|{{!}}{{{sort|}}}}}]]
}}</includeonly><noinclude>
{{documentation}}
{{documentation}}
<!-- Put categories/interwiki on the documentation page -->
<!-- Put categories/interwiki on the documentation page -->

Latest revision as of 09:26, 4 July 2024


[view] [edit] [history] [refresh]Documentation

This template is used to add a category to a template that automatically uses the translation project category for a translation project. Note that this template is useless if you do not have translation projects, so any calls in other templates can be replaced with a direct category link.

Usage[edit source]

|1= can be set to the name of the category. It is used directly on main pages, and |1=/lang is used on translation projects.

If |project= has a value, it won't add a category on the translation project pages.

cs:Šablona:Translation category ja:テンプレート:Translation category th:แม่แบบ:Translation category uk:Шаблон:Категорія перекладу

[view] [edit] [history] [refresh]The above documentation is transcluded from Template:Translation category/doc.