Difference between revisions of "Template:Extension"
Jump to navigation
Jump to search
>Uzume (doc hook90) |
>Uzume (convert back to Template:Foreach as there seem to be problems with Module:Foreach used by Template:Fe) |
||
Line 278: | Line 278: | ||
<div class="mw-collapsible-content plainlist"><ul><li><!-- | <div class="mw-collapsible-content plainlist"><ul><li><!-- | ||
-->{{#ifeq:{{{templatemode|<noinclude>nocats</noinclude>}}}|nocats|<!-- | -->{{#ifeq:{{{templatemode|<noinclude>nocats</noinclude>}}}|nocats|<!-- | ||
-->{{ | -->{{Foreach|Extension/HookInUseNoCats|delim=</li><li>|<!-- | ||
-->{{{hook1}}}|{{{hook2|}}}|{{{hook3|}}}|{{{hook4|}}}|{{{hook5|}}}|{{{hook6|}}}|<!-- | -->{{{hook1}}}|{{{hook2|}}}|{{{hook3|}}}|{{{hook4|}}}|{{{hook5|}}}|{{{hook6|}}}|<!-- | ||
-->{{{hook7|}}}|{{{hook8|}}}|{{{hook9|}}}|{{{hook10|}}}|{{{hook11|}}}|{{{hook12|}}}|<!-- | -->{{{hook7|}}}|{{{hook8|}}}|{{{hook9|}}}|{{{hook10|}}}|{{{hook11|}}}|{{{hook12|}}}|<!-- | ||
Line 296: | Line 296: | ||
-->}}<!-- | -->}}<!-- | ||
-->|<!--else--><!-- | -->|<!--else--><!-- | ||
-->{{ | -->{{Foreach|Extension/HookInUse|delim=</li><li>|<!-- | ||
-->{{{hook1}}}|{{{hook2|}}}|{{{hook3|}}}|{{{hook4|}}}|{{{hook5|}}}|{{{hook6|}}}|<!-- | -->{{{hook1}}}|{{{hook2|}}}|{{{hook3|}}}|{{{hook4|}}}|{{{hook5|}}}|{{{hook6|}}}|<!-- | ||
-->{{{hook7|}}}|{{{hook8|}}}|{{{hook9|}}}|{{{hook10|}}}|{{{hook11|}}}|{{{hook12|}}}|<!-- | -->{{{hook7|}}}|{{{hook8|}}}|{{{hook9|}}}|{{{hook10|}}}|{{{hook11|}}}|{{{hook12|}}}|<!-- | ||
Line 323: | Line 323: | ||
<div class="mw-collapsible-header">{{ll|Template:Extension#newhook|<translate><!--T:31--> Hooks provided</translate>}}</div> | <div class="mw-collapsible-header">{{ll|Template:Extension#newhook|<translate><!--T:31--> Hooks provided</translate>}}</div> | ||
<div class="mw-collapsible-content plainlist"><ul><li><!-- | <div class="mw-collapsible-content plainlist"><ul><li><!-- | ||
-->{{ | -->{{Foreach|Extension/HookProvided|delim=</li><li>|<!-- | ||
-->{{{newhook1}}}|{{{newhook2|}}}|{{{newhook3|}}}|{{{newhook4|}}}|{{{newhook5|}}}|{{{newhook6|}}}|<!-- | -->{{{newhook1}}}|{{{newhook2|}}}|{{{newhook3|}}}|{{{newhook4|}}}|{{{newhook5|}}}|{{{newhook6|}}}|<!-- | ||
-->{{{newhook7|}}}|{{{newhook8|}}}|{{{newhook9|}}}|{{{newhook10|}}}|{{{newhook11|}}}|{{{newhook12|}}}|<!-- | -->{{{newhook7|}}}|{{{newhook8|}}}|{{{newhook9|}}}|{{{newhook10|}}}|{{{newhook11|}}}|{{{newhook12|}}}|<!-- | ||
Line 777: | Line 777: | ||
To change/correct/add to the implementation type parameters: | To change/correct/add to the implementation type parameters: | ||
* Check the [[Template_talk:Extension|talk page]] - there have been some extensive discussions about this field. | * Check the [[Template_talk:Extension|talk page]] - there have been some extensive discussions about this field. | ||
* '''[[Template:Extension/TypeSwitch]]:''' Stores the possible values for the type field. Multiple values are implemented by calling this template with [[Template: | * '''[[Template:Extension/TypeSwitch]]:''' Stores the possible values for the type field. Multiple values are implemented by calling this template with [[Template:Foreach]]. | ||
* '''[[Template:Extension/TypeSwitchNoCats]]:''' Does not need to be modified when adding a new type. Used instead of [[Template:Extension/TypeSwitch]] when this template is used in <code>templatemode=nocats</code>. Templates used with [[Template: | * '''[[Template:Extension/TypeSwitchNoCats]]:''' Does not need to be modified when adding a new type. Used instead of [[Template:Extension/TypeSwitch]] when this template is used in <code>templatemode=nocats</code>. Templates used with [[Template:Foreach]] can only take one parameter so we need to wrap the call to [[Template:Extension/TypeSwitch]] with another template that sets the mode. | ||
To change the behavior of the hook parameters: | To change the behavior of the hook parameters: | ||
* '''[[Template:Extension/HookInUse]]:''' Adds links and categories for a hook in use. Multiple hooks in use are implemented by calling this template with [[Template: | * '''[[Template:Extension/HookInUse]]:''' Adds links and categories for a hook in use. Multiple hooks in use are implemented by calling this template with [[Template:Foreach]]. | ||
* '''[[Template:Extension/HookInUseNoCats]]:''' Used instead of [[Template:Extension/HookInUse]] when this template is used in <code>templatemode=nocats</code>. Templates used with [[Template: | * '''[[Template:Extension/HookInUseNoCats]]:''' Used instead of [[Template:Extension/HookInUse]] when this template is used in <code>templatemode=nocats</code>. Templates used with [[Template:Foreach]] can only take one parameter so we need to wrap the call to [[Template:Extension/HookInUse]] with another template that sets the mode. | ||
== Test case == | == Test case == |
Revision as of 19:46, 13 October 2019
<languages/> Lua error in Module:TNT at line 158: Missing JsonConfig extension; Cannot load https://commons.wikimedia.org/wiki/Data:I18n/Documentation.tab.[[Category:Template documentation pages{{#translation:}}]] Maintenance: vulnerabilities, archived
[[Category:Info templates{{#translation:}}|Extension]] [[Category:Extension creation{{#translation:}}]] [[Category:Categorizing templates{{#translation:}}|Extension]] [[Category:Extension templates{{#translation:}}]]