In php, ($myvariable==0) When $myvariable is zero, the value of the expression is true; when $myvariable is null, the value of this expression is also true. How
($myvariable==0)
If your zero could be a string, you should also considere checking the "zero string"
($myvariable === 0 || $myvariable === '0')