array_diff_uassoc() function in php || PHP Functions

array_diff_uassoc() function in php

0 1365

array_diff_uassoc() function of PHP is used to calculate the difference of two or more associative arrays by using a user define function. It is an inbuilt function of PHP.


array_diff_uassoc ($arr1, $arr2, $arr3, ...,$arrN, function);


  1. $arr1 is the array which values is compared to others.
  2. $arr2,$arr3 and $arrN are the arrays which values is compared to first array and the different values of first array is return as resulting array.
  3. function is a user define function. We calculate the result with the help of this function

Example 1:

function user_function($x,$y)
if ($x===$y)
  return 0;
  return ($x>$y)?1:-1;


Best WordPress Hosting


Discount Coupons

Get a .COM for just $6.98

Secure Domain for a Mini Price

Leave a Reply

    Waiting for your comments