Php array_intersect() function is used to compare two or more arrays and which returns keys and values from array list. which functions have three arguments that are array arr1,array arr2,array arr3.in the first array is use to compare with other arrays. In the second array is a compare with the first array. In the third array is compare with first array and which array is optional.
if you need to example and demo go to at following link.
http://www.tutorialsscripts.com/php-tutorials/array-functions/php-array_intersect-function-demo.php