PHP array_diff_uassoc() functionThis function is inbuilt in PHP and it was introduced in PHP 5. The function array_diff_uassoc() is used to compute the difference of arrays with additional index check which is performed by a user supplied callback function. In simple words, the function compares array1 against array2 and returns the difference. Syntax
Important note: This function uses a user-defined function to compare the keys.Return TypeThis function returns an array containing the entries from array1 that are not present in any of the other ways. Example 1Output: Array( [10] => sid [20] => raj ) Example 2Output: Array ( [b] => brown [c] => blue [0] => red ) Example 3Output: Array ( [c] => orange ) Example 4Output: Array ( [b] => brown [c] => blue [0] => red )
Next TopicPHP Array Functions
|