Home > Backend Development > PHP Tutorial > php array_search() implements array value deletion_PHP tutorial

php array_search() implements array value deletion_PHP tutorial

WBOY
Release: 2016-07-20 11:03:00
Original
983 people have browsed it

The array_search() function, like in_array(), searches for a key value in an array. If the value is found, the key of the matching element is returned. If not found, returns false. ​

The array_search() function is the same as in_array(), searching for a key value in the array. If the value is found, the key of the matching element is returned. If not found, returns false.

If the third parameter strict is specified as true, the key name of the corresponding element will only be returned if the data type and value are consistent

array_search(value,array,strict)

Example

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