Template:Yesno/doc
Jump to navigation
Jump to search
This template/module is sourced/adapted from: Template:Yesno
This template is used for boolean logic, typically within other templates similar to ParserFunctions.
Usage[edit source]
{{Yesno|input|yes=Output if yes}}
{{Yesno|input|yes=Output if yes|no=Output if no|blank=Output if blank|¬=Output if undefined or newline character}}
Template data[edit source]
Boolean logic using yes/no instead of true/false
Parameter | Description | Type | Status | |
---|---|---|---|---|
1 | 1 | The value to be evaluated | String | required |
no | no | Output when input value evaluates to "no" | String | optional |
blank | blank | Specifies the output of the template when the input value is defined but is either empty or contains nothing but whitespace character(s). | String | optional |
¬ | ¬ | Specifies the output of the template when the input value is either '¬' or entirely missing (undefined). | String | optional |
yes | yes | Output when input value evaluates to "yes" | String | optional |
def | def | Specifies the output of the template when the input value is defined but not a form of 'yes', 'no', '1', '0', '¬' or blank. | String | optional |