Difference between revisions of "Template:API-head"

m (Text replacement - "<languages/>" to "")
m (Undo revision 10248 by Joelmartin (talk))
Tag: Undo
 
(3 intermediate revisions by the same user not shown)
Line 6: Line 6:
 
<th {{Databox-head}}>{{{module|{{BASEPAGENAME}}}}}</th>
 
<th {{Databox-head}}>{{{module|{{BASEPAGENAME}}}}}</th>
 
</tr><tr>
 
</tr><tr>
<td colspan="2" style="text-align:center; padding:0.3em; font-style:italic">{{{description|}}}{{#switch: {{{generator|}}} |#default=<br /><small> This module cannot be used as a <tvar|generator>{{ll|API:generator|nsp=0}}</>.</small>|yes=<br /><small> This module can be used as a <tvar|generator>{{ll|API:generator|nsp=0}}</>.</small>}}</td>
+
<td colspan="2" style="text-align:center; padding:0.3em; font-style:italic">{{{description|}}}{{#switch: {{{generator|}}} |#default=<br /><small> This module cannot be used as a <tvar|generator>{{ll|API:generator|nsp=0}}.</small>|yes=<br /><small> This module can be used as a <tvar|generator>{{ll|API:generator|nsp=0}}.</small>}}</td>
 
</tr><tr>
 
</tr><tr>
 
<th> Prefix</th>
 
<th> Prefix</th>
Line 27: Line 27:
 
{{#ifeq:{{{templatemode|}}}|nocat|
 
{{#ifeq:{{{templatemode|}}}|nocat|
 
   |{{#ifeq:{{{generator|}}}|yes
 
   |{{#ifeq:{{{generator|}}}|yes
     |[[Category:MediaWiki API generators{{#translation:}}]]}}
+
     |[[Category:MediaWiki API generators]]}}
 
}}</includeonly>
 
}}</includeonly>
 
| #default=
 
| #default=
Line 85: Line 85:
 
{{clear}}
 
{{clear}}
 
}}
 
}}
[[Category:API templates{{#translation:}}]]
+
[[Category:API templates]]
 
</noinclude>
 
</noinclude>

Latest revision as of 17:13, 21 December 2019


Template documentation

Usage

Displays a box providing more information about an API module.

See also {{ApiEx}} which transcludes the generated API documentation

Examples

{{API-head
|version=1.11
|prefix=sr
|rrights=None
|postonly=No
|description=Perform a full text search
|generator=yes
}}
{{API-head
|module=edit
|version=1.13
|prefix=
|rrights=edit
|postonly=Yes
|description=
|query=no
}}