I have an array that looks something like this:
$array = array(
array('Field1' => 'red', 'Field2' => 'green', 'Field3' => 'blue'),
array('Field1' => 'pink', 'Field2' => 'pinkish', 'Field3' => 'barbiecolor'),
array('Field1' => 'red', 'Field2' => 'blue', ' Field3' => 'orange')
);
And I want to check this by the given values:
$searchBy = array('Field1' => 'red', 'Field2' => 'blue');
What I want to achieve, is to return the parent array that has all associative key & value pairs matched. I've tried in_array() but it doesn't work..