2012-02-02 316 views

回答

3

http://us.php.net/manual/en/language.operators.comparison.php

$a == $b Equal TRUE if $a is equal to $b after type juggling. 
$a === $b Identical TRUE if $a is equal to $b, and they are of the same type. 
$a != $b Not equal TRUE if $a is not equal to $b after type juggling. 
$a <> $b Not equal TRUE if $a is not equal to $b after type juggling. 
$a !== $b Not identical TRUE if $a is not equal to $b, or they are not of the same type. 
+2

只是为了增加一个例子:0 == false,但是0!== false,它是使用strpos函数的最好例子(http:// php。 net/manual/de/function.strpos.php) – roman 2012-02-02 17:14:37

+0

我很感激! – 2012-02-02 17:14:53

+0

真棒!我问这个问题的全部原因实际上与'strpos()'有关! – 2012-02-02 17:16:02