On Fri, Oct 28, 2016 at 10:40 PM, David Harkness <david.h@xxxxxxxxxxxxxxxxx> wrote: > if ($input && ($input = (str) $input)) { ... > Luckily, PHP's automatic string conversion -- (bool) "0" === false -- does not ignore leading spaces. (bool) " 0" === true. Phew! Ciao! David