array_intersect_assoc
PHP 4 >= 4.3.0, PHP 5, PHP 7, PHP 8
array_intersect_assoc - Computes the intersection of arrays with additional index check
array_intersect_assoc(
array$array,
... array$arrays ): array
array_intersect_assoc returns an array containing all the values of array that are present in all the arguments. Note that the keys are also used in the comparison unlike in array_intersect.
Parameters
- array
-
The array with master values to check.
- arrays
-
Arrays to compare values against.
Return Values
Returns an associative array containing all the values in array that are present in all of the arguments.