Difference between revisions of "Template:Both"

From blackwiki
Jump to navigation Jump to search
blackwiki>Plastikspork
(remove non-existing link)
blackwiki>RockMFR
(moved to Template:Both/doc)
Line 1: Line 1:
{{#if:{{{1|}}}|{{#if:{{{2|}}}|1|}}|}}<noinclude>{{pp-template|small=yes}}''Usage:'' <nowiki>{{both|string1|string2}}</nowiki>
+
{{#if:{{{1|}}}|{{#if:{{{2|}}}|1}}}}<noinclude>
 
+
{{pp-template}}
Produces '''1''' (equivalent to a true condition) if both ''string1'' and ''string2'' are non-empty; otherwise produces the empty string (false condition).
+
{{documentation}}
 
+
</noinclude>
[[Category:Boolean, register, and condition testing templates]]</noinclude>
 

Revision as of 02:39, 21 September 2009

Template documentation[view] [edit] [history] [purge]

Usage

{{Both|string1|string2}}

Produces 1 (equivalent to a true condition) if both string1 and string2 are non-empty; otherwise produces the empty string (false condition).

TemplateData

This is the TemplateData documentation for this template used by VisualEditor and other tools; see the monthly parameter usage report for this template.

TemplateData for Both

Produces '1' (equivalent to a true condition) if both 'string1' and 'string2' are non-empty; otherwise produces the empty string (false condition).

Template parameters

ParameterDescriptionTypeStatus
String11

First string

Stringrequired
String22

Second string

Stringrequired

See also