Template:If: Difference between revisions

From Heroes 3 wiki
Jump to navigation Jump to search
No edit summary
m (add category)
 
(4 intermediate revisions by one other user not shown)
Line 1: Line 1:
{{ {{{|safesubst:}}}p{{ {{{|safesubst:}}}#ifeq:{{{1}}}|eq|1|2}}|{{ {{{|safesubst:}}}p{{ {{{|safesubst:}}}#ifeq:{{{2}}}|{{{3}}}|1|2}}|{{{4|}}}|{{{5|}}}}}|{{ {{{|safesubst:}}}p{{ {{{|safesubst:}}}#if{{{1}}}:{{{2}}}|1|2}}|{{{3}}}|{{{4|}}}}}}}<noinclude>
<includeonly>{{ {{{|safesubst:}}}p{{ {{{|safesubst:}}}#ifeq:{{{1}}}|eq|1|2}}|{{ {{{|safesubst:}}}p{{ {{{|safesubst:}}}#ifeq:{{{2}}}|{{{3}}}|1|2}}|{{{4|}}}|{{{5|}}}}}|{{ {{{|safesubst:}}}p{{ {{{|safesubst:}}}#if{{{1}}}:{{{2}}}|1|2}}|{{{3}}}|{{{4|}}}}}}}</includeonly><noinclude>


See [https://www.mediawiki.org/wiki/Template:If this page] for usage.
See [https://www.mediawiki.org/wiki/Template:If this page] for usage.


[[category:templates]]</noinclude>
In many cases you may be able to use the basic #if parser function instead:
:<nowiki>{{#if:test string|value if test string is not empty|value if test string is empty (or only white space)}}</nowiki>
:→ {{#if:test string|value if test string is not empty|value if test string is empty (or only white space)}}
 
[[category:Text templates]]</noinclude>

Latest revision as of 22:26, 8 December 2023


See this page for usage.

In many cases you may be able to use the basic #if parser function instead:

{{#if:test string|value if test string is not empty|value if test string is empty (or only white space)}}
→ value if test string is not empty