In PHP 0 is treated as boolean false. Hence, whenever I'm in a situation where a function has to return a numerical value and I have it return 0, or when I have a MySQL bool column with possible values of 0/1, and I use code such as this:
$active=(isActive()) ? 1 : 0;
$this->db->set('isActive',$active);
I get a feeling in the back of my mind that the 0 might be converted to null or an empty string e.g "".
What precautions do I need to take in order to have 0 always treated as an integar and not anything else?