The strchr() function used for find first occurrence of a string inside another string.
Alias of strstr()
Syntax
strchr(string,search,before_search);
Example
echo strchr("Hello Dear","Dear",true);
Output
Hello
Copyright ©2022 coderraj.com. All Rights Reserved.