What does "===" mean?

Stefan Konno picture Stefan Konno · Jul 13, 2009 · Viewed 66.7k times · Source

I've noticed someone using the PHP operator === which I can't make sense out of. I've tried it with a function, and it corresponds in crazy ways.

What is the definition of this operator? I can't even find it in the declaration of PHP operators.

Answer

Tim Sylvester picture Tim Sylvester · Jul 13, 2009
$a === $b     (Identical)      

TRUE if $a is equal to $b, and they are of the same type. (introduced in PHP 4)

PHP Docs