array_intersect_uassoc

PHP 5, PHP 7, PHP 8
array_intersect_uassoc - Computes the intersection of arrays with additional index check, compares indexes by a callback function
Manual
Code Examples

Example #1 array_intersect_uassoc example

Result: Array ( [b] => brown )
PHP Version: