What is the use of strpos function in PHP?

In this blog, We are going to learn,use of strpos String function in PHP?

strpos() Function: This function helps us to find the position of the first occurrence of a string in another string. This returns an integer value of the position of the first occurrence of the string. This function is case-sensitive, which means that it treats upper-case and lower-case characters differently.

$myString = 'Best Couple';

echo strpos($myString, "Couple");

OUTPUT : 5

I hope that you found this Blog helpful. If you’ve any queries, please leave comments in the comment section.

Thanks for following and reading this blog.