模板:Xpds:修订间差异

来自SINO云课堂
(创建页面,内容为“<includeonly>{{#invoke:xpd|s}}</includeonly><noinclude> This Template:xpds (expansion demo) shows the call of a variable, parser function or template and its re…”)
 
(导入1个版本)
 
(没有差异)

2018年5月5日 (六) 10:24的最新版本


This Template:xpds (expansion demo) shows the call of a variable, parser function or template and its result, for documentation. The call is the same as the template call to be demonstrated, except that "xpds|" is inserted after the opening braces.

The template uses Module:Xpd; see also Module talk:Xpd.

Examples:


{{xpds|CURRENTTIME}} gives: {{CURRENTTIME}} → 06:50


{{xpds|#expr:1/7}} gives: {{#expr:1/7}} → 0.14285714285714


{{xpds|2x|[[abc]] }} gives: {{2x|[[abc]] }}abc abc


{{xpds|{{#expr:7-5}}x|{{#expr:1/7}} }} gives: {{2x|0.14285714285714 }} → 0.14285714285714 0.14285714285714


{{xpds|t2demo||abc}} gives: {{t2demo||abc}} → start--middle-abc-end


{{xpds|SeeHook|ParserBeforeStrip}} gives: {{SeeHook|ParserBeforeStrip}} → [[Manual:Hooks/ParserBeforeStrip{{#translation:}}|ParserBeforeStrip]] /en


{{xpds|Foreach|SeeHook|delim=,|ParserBeforeStrip|ParserAfterStrip}} gives:

{{Foreach|SeeHook|ParserBeforeStrip|ParserAfterStrip|delim=,}} → [[Manual:Hooks/ParserBeforeStrip{{#translation:}}|ParserBeforeStrip]] /en,[[Manual:Hooks/ParserAfterStrip{{#translation:}}|ParserAfterStrip]] /en

See also