json string PHP stristr function case-insensitive string search

WBOY
Release: 2016-07-29 08:42:58
Original
1012 people have browsed it

Returns the remainder of the string (from the matching point) if the lookup is successful, or false if the string is not found.
Version support: PHP 3+
Syntax:
stristr(string,find)
Description:
string required. Specifies the string to be searched for.
find required. Specifies the characters to search for. If the argument is a number, searches for characters that match the ASCII value for that number.
Tip:
This function is binary safe.
This function is not case sensitive. For case-sensitive searches, use strstr().
Example:
Example 1

Copy the code The code is as follows:


echo stristr("Hello world!","WORLD");
?>


Output:
world !
Example 2

Copy the code The code is as follows:


echo stristr("Hello world!",111);
?>


Output:
o world!

The above introduces the case-insensitive string search of json string PHP stristr function, including the content of json string. I hope it will be helpful to friends who are interested in PHP tutorials.

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!