Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

find value in array php

//array_search
$result = array_search("apple", $fruit_array); // return index or false

//in_array
$result = in_array("apple", $fruit_array); // return true or false
 
PREVIOUS NEXT
Tagged: #find #array #php
ADD COMMENT
Topic
Name
1+9 =