Is there any builtin function for PHP that will take a boolean value and return its integer equivalent? 0 for FALSE, 1 for TRUE? Of course you can easily create a function to do
Use type casting (bool):
var_dump((bool) 1); // bool(true) var_dump((bool) 0); // bool(false)