Actually, with the "==" operator, all of the following evaluate as equal to each other: 0, "0", "", false, null. Many times you can get away with this loosely typed comparison, but you need to be careful when, for instance, a zero is a valid entry but nothing entered at all is not valid. If I'm testing simply to see if anything was entered, I typically trim() the value and then use the "===" identical operator:
if('' === trim($_POST['field']))
{
// raise error for empty field.
}
(Note that the empty() function is like the "==" operator, in that it returns true if the variable is not set or if it evaluates to 0, so will return true for any of those values listed above.)