PHP is_null() and ==null

nullphp

In PHP, what is the difference between is_null and ==null in PHP? What are the qualifications for both to return true?

Best Solution

is_null is the same as === null. Both return true when a variable is null (or unset).

Note that I'm using === and not ==. === compares type as well as value.