Module:Cite/doc: Difference between revisions

Content deleted Content added
deps
m ce;
 
(One intermediate revision by the same user not shown)
Line 8:
 
===Examples===
This module requires onlyno oneparameters parameter:but thedoes first positional parameter. That parameter takes as a value,require the canonical name of a cs1 template without the <code>cite</code> prefix: <code>cite book</code> → <code>book</code>, <code>cite web</code> → <code>web</code>. To replace {{tlx|citation}} templates, use <code>citation</code>.
 
The structure for calls to this module:
:<code>{{<nowiki/>{{color|#00F|#invoke}}:cite |cite |&lt;{{var|template name}}>|&lt;{{var|cs1 parameters}}>}}</code>
where:
:<code>{{color|#00F|#invoke}}:cite</code> – calls this module: Module:cite
:<code>|cite&lt;{{var|template name}}></code> – is the functioncanonical inname Module:citeof thatthe istemplate towithout be executed:the <code>cite()</code> prefix; this is the <code><nowiki>#invoke:</nowiki></code> function call; case insensitive
:<code>|&lt;{{var|template name}}></code> – is the canonical name of the template without the <code>cite</code> prefix
:<code>|&lt;{{var|cs1 parameters}}></code> – are all of the parameters required by {{tld|cite &lt;template name>}}
 
Line 22 ⟶ 21:
::{{cite book |author=EB Green |date=1915 |title=Title |publisher=PseudoRandom}}
write:
:<syntaxhighlight lang="wikitext" inline="1">{{#invoke:cite |cite |book |author=EB Green |date=1915 |title=Title |publisher=PseudoRandom}}</syntaxhighlight>
::{{#invoke:cite |cite |book |author=EB Green |date=1915 |title=Title |publisher=PseudoRandom}}
 
 
==TemplateData==
{{TemplateData header}}
<templatedata>
{
"description": "This module for use on articles that are approaching the post-expand include size limit. For all other usage information, see [[Module:Cite]].",
"params": {
"1": {
"label": "1",
"description": "canonical name (without the 'cite' prefix) of the template to be replaced; to replace 'cite book', use 'book'.",
"type": "string",
"required": true
}
}
}
</templatedata>
 
<includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox | |