Answers for "find str in str php"

PHP
5

php find if substring is in string

$result = strpos("haystack", "needle");

if ($result != false)
{
  // text found
}
Posted by: Guest on March-13-2020
0

php find string in string

$pos = strpos("find the position of X in here", "X");
Posted by: Guest on March-16-2021

Browse Popular Code Answers by Language