if($condition, $if-true, $if-false)
Returns one of two values, depending on whether or not $condition
is true. Just like in @if
, all values other than false
and null
are considered to be true.
if($condition, $if-true, $if-false)
Returns one of two values, depending on whether or not $condition
is true. Just like in @if
, all values other than false
and null
are considered to be true.
Examples:
if(true, 1px, 2px) => 1px
if(false, 1px, 2px) => 2px
Parameters:
Returns:
Designed by : w10schools
service@w10schools.com
Please login to continue.