zf2 form filter treat 0 as integer and empty string as null

661 Views Asked by At

This question may be obvious to some :)

I've got an input which needs to handle numeric values and then filter/validate when empty as null. Every method I've tried has resulted in the value either being treat as 0 both when empty and having a value of 0 or as null when empty or having a value of 0.

Thanks in advance.

0

There are 0 best solutions below