Fine is the given value is exists or not in array in php

Uncategorized 0 Comment 5

Function for Finding if the value is exists or not in the array given array
in_array(search element, array)
This function return TRUE if the given value is exists in the array otherwise return FALSE
Note: if the search parameter is a string and the type parameter is set to TRUE, the search is case-sensitive

Function for finding the key value is exists or not in the given array
Array_key_exists(key, array)
Note: that if you skip the key when you specify an array, an integer key is generated, starting from 0 and increase by 1 for each value.

Leave a comment

You must be logged in to post a comment.

© 2016 4frienz. Powered By Flowers

Back to Top