Acciones

Plantilla

Diferencia entre revisiones de «If both/doc»

De La Venciclopedia

mSin resumen de edición
mSin resumen de edición
 
(No se muestran 5 ediciones intermedias del mismo usuario)
Línea 1: Línea 1:
{{Subpágina de documentación}}
{{subpagina de documentacion}}<!-- PLEASE ADD CATEGORIES AND INTERWIKIS AT THE BOTTOM OF THIS PAGE -->
<!-- PLEASE ADD CATEGORIES AND INTERWIKIS AT THE BOTTOM OF THIS PAGE -->
__NOTOC____NOEDITSECTION__
__NOTOC____NOEDITSECTION__
Esta plantilla incluye un texto o código si dos parametros son verdaderos.


This helper template is designed to be used in other templates. It can help editors create template code that is self-documenting.
=== Uso ===
SI '''a''' y '''b''' entonces VERDADERO.


=== Usage ===
SI '''a''' ni '''b''' entonces FALSO.
If '''a''' and '''b''' then true.


If '''a''' nor '''b''' then false.
SI '''a''' o '''b''' entonces FALSO.


If '''a''' or '''b''' then false.
Puede usarse para reemplazar el código: <code><nowiki>{{#if:a|{{#if:b|verdadero|falso}}|falso}}</nowiki></code>


It can be used to replace the construct: <code><nowiki>{{#if:a|{{#if:b|true|false}}|false}}</nowiki></code>
=== Ejemplos ===


=== Examples ===
<code><nowiki>{{if both| a | b |verdadero|falso}}</nowiki> → {{if both| a | b |verdadero|falso}}</code>


<code><nowiki>{{if both| a | b |true|false}}</nowiki> → {{if both| a | b |true|false}}</code>
<code><nowiki>{{if both| a | |verdadero|falso}}</nowiki> → {{if both| | b |verdadero|falso}}</code>


<code><nowiki>{{if both| a | |true|false}}</nowiki> → {{if both| | b |true|false}}</code>
<code><nowiki>{{if both| | b |verdadero|falso}}</nowiki> → {{if both| | b |verdadero|falso}}</code>


<code><nowiki>{{if both| | b |true|false}}</nowiki> → {{if both| | b |true|false}}</code>
<code><nowiki>{{if both| |  |verdadero|falso}}</nowiki> → {{if both| |  |verdadero|falso}}</code>
 
<code><nowiki>{{if both| |  |true|false}}</nowiki> → {{if both| |  |true|false}}</code>


=== Ver también ===
=== Ver también ===
Línea 28: Línea 26:
* {{tl|if empty}}
* {{tl|if empty}}
* {{tl|if all}}
* {{tl|if all}}
<includeonly>{{Sandbox other||
<includeonly>{{Sandbox other||
<!-- CATEGORIES GO HERE -->
<!-- CATEGORIES GO HERE -->
[[Categoría:Plantillas If-then-else]]
[[Categoría:Venciclopedia:Plantillas If-then-else|{{PAGENAME}}]]
[[Categoría:Venciclopedia:Lista de plantillas]]
<!-- INTERWIKIS GO HERE -->
<!-- INTERWIKIS GO HERE -->
}}</includeonly>
}}</includeonly>
<noinclude>[[Categoría:Venciclopedia:Plantillas de uso|{{PAGENAME}}]]</noinclude>

Revisión actual - 14:28 1 oct 2020

Esta plantilla incluye un texto o código si dos parametros son verdaderos.

Uso

SI a y b entonces VERDADERO.

SI a ni b entonces FALSO.

SI a o b entonces FALSO.

Puede usarse para reemplazar el código: {{#if:a|{{#if:b|verdadero|falso}}|falso}}

Ejemplos

{{if both| a | b |verdadero|falso}} → verdadero

{{if both| a | |verdadero|falso}} → falso

{{if both| | b |verdadero|falso}} → falso

{{if both| | |verdadero|falso}} → falso

Ver también