Hello,
I am having one associative array in PHP which contains some 10 name value pairs & I want to check it must contains at least one value in that array. How can I do that? Please help me. Thanks in advance.

    If you want to test if the array has at least 1 element:

    if( ! empty($array)) {
    

    If you want to test that a specific element exists in the array:

    if(isset($array['element_name'])) {
    
      Write a Reply...