Kort version:
if ("$myVal" === '0')
eller
if (strval($myVal) === '0')
Lang version:
if ($myVal === 0 || $myVal === '0')
Kort version:
if ("$myVal" === '0')
eller
if (strval($myVal) === '0')
Lang version:
if ($myVal === 0 || $myVal === '0')