the developer can name this file ./EXAMPLES/ARRAY/find.php

please note the

strpos or stripos !== false

without it, if a substring is found within a string at position 0

for if 0 equals false

<?php
$mystring = 'abc';
$findme = 'a';
$pos = strpos($mystring, $findme);
$pos = stripos($mystring, $findme); // do not care about upper or lower case

// The !== operator can also be used. Using != would not work as expected
// because the position of 'a' is 0. The statement (0 != false) evaluates
// to false.
if ($pos !== false)
{
echo "The string '$findme' was found in the string '$mystring'";
echo " and exists at position $pos";
}
else
{
echo "The string '$findme' was not found in the string '$mystring'";
}
?>
admin