Boolean > Boolean value Favorite

Matches "truthy" or "falsy" text values 1/0, y/n, yes/no, t/f, true/false or on/off.

Sample Matches
Text Result
0
Group #0
0
Group #2
0
match
1
Group #0
1
Group #1
1
match
n
Group #0
n
Group #2
n
match
y
Group #0
y
Group #1
y
match
no
Group #0
no
Group #2
no
match
yes
Group #0
yes
Group #1
yes
match
f
Group #0
f
Group #2
f
match
t
Group #0
t
Group #1
t
match
false
Group #0
false
Group #2
false
match
true
Group #0
true
Group #1
true
match
off
Group #0
off
Group #2
off
match
on
Group #0
on
Group #1
on
match
maybeno match
Match Groups
1
"truthy" value
2
"falsy" value
Notes

You can test whether the value was truthy or falsy based on the match groups like this (PHP):

preg_match('/.../', 'true', $matches);
$value = (bool)$matches[1];