PHP – Merging two arrays into one array (also Remove Duplicates)

array_unique(array_merge($array1,$array2), SORT_REGULAR);

http://se2.php.net/manual/en/function.array-unique.php

Leave a Comment