note 48243 deleted from function.strpos by tularis
| From: | tularis@php.net | Date: | Thu, 16 Dec 2004 12:17:01 +0000 |
| Subject: | note 48243 deleted from function.strpos by tularis | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-81860@lists.php.net to get a copy of this message | ||
Note Submitter:
----
This code will not work as excepted:
<?php
if (strpos("TEST", "T")===TRUE){
echo "match";
} else {
echo "no match";
}
?>
this one will work as excepted:
<?php
if (strpos("TEST", "T")!==FALSE){
echo "match";
} else {
echo "no match";
}
?>
So be careful when using === .
----
Reason: useless example