Greetings,
= assigns variable on left the value on the right.
== determines equality
=== determines equality AND type
So you'd use = like so;
Code:
$somevar = 'A string variable';
you'd then use == like so;
Code:
if( $somevar == 'A string variable' )
{
echo 'Match found';
}
else
{
echo 'Match NOT found';
}
and finally;
Code:
if( ($pos = strpos($somevar, 'string')) !== false )
{
echo 'Found "string" at position: ' . $pos . ' in string: "' . $somevar .'"';
}