array unique php

Solutions on MaxInterview for array unique php by the best coders in the world

showing results for - "array unique php"
Maelie
28 Jul 2017
1<?php
2$fruits_list = array('Orange',  'Apple', ' Banana', 'Cherry', ' Banana');
3$result = array_unique($fruits_list);
4print_r($result);
5?>
6  
7Output:
8
9Array ( [0] => Orange [1] => Apple [2] => Banana [3] => Cherry ) 
Paulina
22 Jan 2019
1
2<?php
3$input array("a" => "green""red""b" => "green""blue""red");
4$result = array_unique($input);
5print_r($result);
6?>
7
8Array
9(
10    [a] => green
11    [0] => red
12    [1] => blue
13)
Valeria
14 Jan 2017
1<?php
2    // Syntax: array_unique(array $array, int $flags = SORT_STRING): array
3    // Desc: Removes duplicate values from an array
4    $arr = Array("red", "red", "green", "blue", "blue", "white");
5    echo "<pre>";
6    print_r($arr);
7    echo "</pre> <br><br>";
8    
9    $arrUnique = array_unique($arr);
10
11    echo "<pre>";
12    print_r($arrUnique);
13    echo "</pre> <br><br>";
14
15    /* -------- output -----------
16    Array
17    (
18        [0] => red
19        [1] => red
20        [2] => green
21        [3] => blue
22        [4] => blue
23        [5] => white
24    )
25    
26    Array
27    (
28        [0] => red
29        [2] => green
30        [3] => blue
31        [5] => white
32    )
33    */
34?>
Wilbert
04 Jul 2019
1$counts = array_count_values($array);
2            $duplicate_title  = array_filter($array, function ($value) use ($counts) {
3                return $counts[$value] > 1;
4            });
Isabella
01 Oct 2020
1let chars = ['A', 'B', 'A', 'C', 'B'];
2let uniqueChars = [...new Set(chars)];
3
4console.log(uniqueChars);
5
Della
08 May 2019
1$input = array_map("unserialize", array_unique(array_map("serialize", $input)));
queries leading to this page
array unique by key value in phpfind duplicate in an array in php without using functionremove duplicates from an array phpphp create array with unique valuesdelete duplicates array phpphp remove duplicate arrays phpdelete duplicates from array phpduplicate in array phpmake unique arrayhow to get count of duplicate value in associative array using phparray unique in laravelphp function to remove duplicates in an arraylist unique phpfind unique elements from array in php without functionarray compare php and remove not repeatedcheck if any duplicates between two arrays phpphp get unique item in result array phpphp regex remove duplicatesto remove duplicate based on a id in arrayget unique elements from associative array phpduplicated items in array phpphp check if array contains duplicateshow to get array without duplicatesremove duplicates from array in phpunique value value in phpphp remove duplicates from array differenthow to remove duplicate elements from array in phphow to remove repeated elements in an arrayunique php arrayphp array unique by item valueif you are given an array 2c remove duplicates from itarray unique associative phpcheck if array has duplicate values phparray check duplicates phpphp get unique name in php two array how to remove duplicates elements in an array in javascriptarray unique 28 29remove duplicate data in phpphp array exclude duplicatesremove specific duplicate key value from array phpremove all duplicates from an arrayarray unique on id phpmerge arrays php remove duplicatesfind array unique element in php associative arrayremove duplicate array in array list in phpphp unique in array onlyhow to remove the repeated value in array in phparray same variable remove in phpphp remove nested arrayhow to remove the duplicated numbers of array in phpphp array filter with unique valueavoid duplicate values in foreach phpremove duplicates from array listphp add to array detect duplicate valuesphp array merge distinctphp foreach loop check duplicate valuesremove all duplicate elemetn in arrayphp array delete repeated valuesremove duplicate vallue from array in phpremoving duplicates form an arraycheck array for duplicate key phpeliminate duplicate element from array in javascriptphp make search similar value in arrayphp array strip duplicatehow to remove duplicate elements in array phphow to get unique key value from associative array in phpphp remove identical values from arrayduplicate dates in phpfinding unique indexes in array in phpget no of duplicates array phpremove the duplicate rows from an array phpphp array count duplicatesif array has duplicates data phpremove repeat value in array phpskip duplicate id in phphow to eliminate repeated data in array phpphp check array for duplicatesdelete dduplicated from array phpremove duplicated entrier from array phparray number unique phpget only unique values from array in pharray duplicate index remove in phphow to remove duplicate values from array in php without using functionreturn array with duplicates remoeddelete dublicate valie in array phpphp remove duplicate element in arrahow to stop duplicate entries in array javascripthow to remove duplicate object in array phpuse array map to return duplicate values in phpphp array unique maplaravel array remove duplicatesremove duplicate elements from associative array in phpremove duplicate foreach phpphp remove duplicates from array by valueget unique item from array phphow to remove repeated elements in an array pphpremove duplicated array phparray merge unique by fieldremove duplicates element array phpphp print one value if duplicatehow to delete duplicate in js arrayremove duplicate strings from array in cremove duplicates in array listphp check for duplicates in arrayphp check if duplicate value in arrayphp function to remove the duplicate valuesdelete duplicates in arrayarrayuniquephp declarar array unique 28 29duplicate in array in phpremove duplicate arrays in array phpremove duplicates in php arrayphp array unique valuerphp array check duplicate valueshow to remove ve duplicates in phparray uniuq in phpunique item in list phpcode to remove duplicates from an arrayselect unique kewy value php arrayarray remove duplicates blank valueremove duplicate key values from array phparray value unique phpdelete duplicate arrayremove same item from array phpphp array keys uniquerhow to check duplicate in array phpdetect duplicates in array phparray unique associated array with array field phpfind duplicate array values phpduplicate value remove in array phpphp remove duplicate values from arrayremove duplicate array object php greeperremove duplicates from collection array phparray unique without array function phpremove duplicate value fron array in phpdetect all duplicate items in php arrayarray distint phpphp array keys uniquephp get unique values in an arrayremove repeated values in array phptake unique values from request array phpcheck if array contains duplicates phparray unique key phpphp check for duplicate values in arrayfilter unique value from arrays in an array in php php array column uniquephp search same value in arrayget unique value from array phpphp array check for duplicate valuesphp array map unique valuesphp find duplicate values in arrayremove particular duplicate value from array in phpremove all duplicate array phphow to get unique array of objects values phpget unique values array laravelcreate unique key in phpmethod to remove duplicate num from arrayphp remove duplicates from array without using inbuilt functionremove duplicate from array phparray duplicate valuephp array return unique valuesphp unique array based on valueremove duplicate elements phphow to get only reptead value in phpdelete dublicated element from array phphow to find duplicates in an array in php without the keysremove duplicates from array javascriptdelete all duplicates from array phpphp remove duplicate but keep lowest valueremove duplicate data from array in phpphp get unique values from objecphp array unique array valuesremove repeated values in php strninghow to get unique arrays in phpphp check duplicate array valuesadd index to value on duplicate array phpphp count repeated values in arrayfunction to remove duplicates values from an array in phpphp array get all duplicate valuesremove duplicates values from associative array phpunique array of arrays phpremove php array duplicatesmake a unique array on phpcount duplicate values in array phpphp unique array keysremove duplication arrayhow to get duplicate value in array using php loopdelete repeated index in array phpphp make unique arrayphp values in unique arrayphp array unique values between arrays phparray remove duplication phpremove duplicate from list jshow to remove duplicates in arrays phpremove duplicate elements from array in php without using functionremove duplicates in phpphp array filter remove duplicateshow to get to know whether you have duplicates in phpremove duplicate value in array javascriptphp remove duplicates values from arrayremove array unique with specific index duplicate phpremove duplicate values in array in phpfind duplicates phpphp remove duplicates from array foreachremove duplicate numbers from unsorted arrayif array is duplicate values phparray unique decroissant phpremove the duplicate from key value array in phparr remove duplicatesphp array key uniquehow to remove duplicate values from associative array in phparray remove duplicates values phparray to remove duplicate values phparray delete duplicates phpremove dublicate in array phpcheck duplicates in array phpget duplicate values in phpphp array column value duplicate get keyremove duplicates from array and keep same ordercounting duplicates phparray unique removing keyremove dublicates from array phparray unique laravelarray remove duplicates javascriptphp array filter all duplicate valuesget unique keys arrayremove duplicate rows in array phpphp create array with unique rowsduplicate elements in array phpphp array remove duplicate values 2b emptyremove repeated elements in list phpcreate array with unique keys phpremove dublicate values from arrayphp array sort uniquephp check array unique onlneremove duplicate array phpphp remove duplicate in arrayremove duplicate in array brubyremove duplicate and trim array phpcheck duplicate values in array phpremove duplicate values for same value in an array phparray unique no keyremove duplicate array object phphow to remove duplicate value from array without using any array function in phpphp array uniquehow to check doublecate value in array phpwrite a php program to remove duplicate values from an array which contains only strings or only integers array unique valuesphp check array values samesremove duplicate value in array phpgrab unique index from php arrayphp unique array of objectsarray unique in php by columnremove duplicates from array unsortedhow to prevent duplicate entries in phpdistinct laravel arrayreturn the dublicated values in array in phphow to delete duplicates string in foreach in phphow to find uniques values from array in php e2 80 9cif there are duplicate values in an array 2c get only once php e2 80 9d code answerremove duplicates string from array jsduplicate checking php 2d arrayhow to remove duplicate numbers from array in javascriptunique values php arrayremove duplicate value by keys in associative array in phpremove duplicate phpremove duplicates from multidimensional array phpoutput only 1 duplicate value in array phpphp associative array unique keyremove duplicates in array for same elementphp array unique errorphp remove duplicates values remove duplicate rows array phpget unique values from an array in phpphp remove duplicates from array and reorder indexphp unique array numeric array valuesremove same data form arrayarray in array key values uniquedeleting the same element from php arraydelete duplicate entry in array phphow to delete duplicate elements in an arrayremove duplicates from the linked list using phpcheck if elements are repeating in array phpdelete array duplicate phpphp array duplicate valuephp check duplicate remove all duplicate key value from php arrayphp duplicate array php array duplicate valuesarray uniquearray unique using method in phpremove duplicates from array javascript using filterarray duplicates delete phphow to remove duplicates in javascript arrayhow to unique associative array in phpphp get unique values from 1d arrayphp remove dupliocates from arrayphp check if array has duplicateshow to remove duplicate values from array in phphow to delete duplicate data from an arrayarray unique array to string conversionremove duplicates from foreach phphow to array duplicate remove in phpremove whole array if duplicate key value found phparray unique 28 24matches 5b1 5d 29remove duplicate elements from multidimensional array in phpphp find same values in arrayphp array with repetitive elements how to get rid of when echo outduplication data remove from array in phpwrite a php a function to remove a specified 2c duplicate entry from an arrayhow to remove duplicate values from a multidimensional array in phpphp two array remove duplicatesphp remove duplicate valuearray duplicating value searching using phpjavascript array remove repeated valuesphp check and remove duplicates from arrayphp auto check duplicate values in arrayarray unique object phpphp array remove duplicates custom checkdont remove duplicate array phpfind duplicate object in array phparray remove duplicate phpphp array unique not removing duplicatesphp multidimensional array remove duplicatescreate array and remove duplicates phparray unique in php with indexphp array duplicate removeremove duplicate value in arraytphp unique elements in arrayif there are duplicate values in an array 2c get only once phphow to add to array in single without repetation in phpphp get unique arrayarray filter out duplicate items in phparray remove same value phpphp nrry find not unique valuephp find duplicate values in associative arraycheck repeated values in array phpphp array set avoid duplicatesfind duplicate in array phpunique values array phpremove duplicate element from array in phpphp get duplicate count arrayarray keys unique phphow to remove duplicates in a php arrathow to serial key after array unique value in phpremove duplicate element for unsorted arrayarray unique php on spefic keybest data structure in php for a unique valuesphp make a unique string from arrayarray unique php by value associativephp eliminate duplicates from assocaitive arrayremove duplicates arrays phparray foreach for duplicate checking in phparray get same val phpcheck same value in array phpunique variables array phparray unique in laravelphp array unique associativejavascript array remove duplicatesremove duplicate array elements phpremove duplicates in an array in phpphp array remove duplicate arrayremove duplication phpremove duplicates from string phphow to identify number count repeated values in array in phpfind duplicate in array and remove in jshow to remove duplicate value sin an arrayphp remove duplicates from array multidimensionalhow to delete repeated element in arrayremove duplicate string from arrayremove repeated elements in php arrayphp find duplicate number in arrayremove duplicates php sqlhow to remove the common data from the array phpphp while distinctsame value remove in phpphp array remove duplicates by valueobject key by unique phpphp array duplicate values removehow to remove duplicates without shorting the arrayhow to check duplicate entries in phpremove all same array value in phpremove all duplicates from array phpdistinct array repetidosi have multiple arrays and i want to user array unique on that in phparra uniquecheck if array is duplicate and get the latest values phpcheck duplicate value in multidimensional array phpphp array merge and remove duplicateshow to remove duplicates from a sql query with phpremove duplicate elments from array jsremove duplicate from multidimensional array phpphp check same value in arrayremove duplicate arrays from array phpphp array remove duplicate valueremove duplcates array phpremove duplicate value phpremove duplicate values inside foreach phpfind unique elements in array phpphp unique array setremove duplication array phpphp array dublicate removephp remove duplicacte ids htmlphp unique values in arrayphp unique arrayphp get non unique values from arrayphp unique element in arrayeliminate duplicates in array javascriptget same values from array phpassoc key unique phparray duplicate remove phpphp check duplicate entryremove the duplicate element in arrayremoving duplicates from array phpremove duplicates from php arrqayhas duplicate in array phphow to remove the duplicate numbers of array in phpphp strip array of duplicatesphp remove duplicate valuesremove duplicates value in index array phpphp array remove duplicate valuesarray unique with index valueremove repeated values from array phphow to check array repetition phparray unique in php by valuephp set array uniquearray unique for key and value in phphow to delete a duplicate value in an array phparray push distinct values phpphp check duplicates in arrayi have multiple arrays and i want to user array unique on that javascript array string remove duplicatesarray unique sort phparray duplicates phpremove duplicate words array phpuse destinct arratyt phphow to print array with unique in phpphp add unique to arrayremove the duplicate elements in array in phpphp array map uniqueremoving duplicates from array in javascriptreturn array without duplicates phpget unique form array laravelremove duplicates php arrayremove same value from array phpphp remove dupicates key from arrayarray unique is not working on array of objects in phphow to remove duplicate row but keep one in phpremove dulicate valures in an arrayarray unigue phpremoving duplicates from arrayhow to remove duplicate values form array phpphp uniqe arrayprevent array from duplicate in phpremove duplicates from an array without using any php function in phpphp array duplicate value make uniquephp array uniquemake array uniquemake array unique php based on the valuesremove duplicates forom arrayphp array get unique request uri combinations strings bij arrayphp remove replications in arrayarrray unique in phpmake array values unique phphow to removed duplicate entryin arryahow to get duplicate values in php arraydelete duplicate elements in an arrayarray unique 28unique of array phpphp function to remove duplicate values from arrayphp get unique objects in arrayecho unique array phpphp function remove array duplicatesget unique array value phpdelete duplicates in an array phpphp remove duplicates from integer arrayget unique values from associative array phpphp array unique returns objecthow to remove duplicate item in array javascriptdelete duplicate values in array phphow to make values of a associative array uniqueremove duplicates by value from multidimensional array phpremove duplicate item from an arrayhow to remove all repeated number in array array unique 28 29distinct array phpphp remove duplicatesremove dulicate from array smarrtyphp unique arra yvaluewhat if the key value is not unique phpfunction to remove duplicates in phpfind unique in array phpmake array uniqremove duplicates in an array phpfunction to preserve duplicate value index in phpphp array unique valueshow to remove duplicates in array pythonfind duplicate value array phparray unique for objects instead of string phpwrite code to remove duplicate from arrayhow to find distinct values from an array in phpunique values in array phpwhat does array unique php dohow to remove all duplicates from an arrayphp get remove repeated values in arrayprnit not duplicate from array phpphp array delete double entriesarray unique phpphp distinctremove the duplicates from an array using javascript without creating a new arrayset parameteres in array unique method in phpreturn unique phpphp check unique in arrraybindexhow return array unique in phpmost efficient way to remove duplicates in an arrayfastest way to remove duplicates from arrayphp remove repeated values in arrayarray php remove duplicatesfind number that not duplicate in phparray unique by keys return 1 associative array item in phpshow duplicated value phparray with unique values phpphp get unique values from arraydelete duplicate array phpphp array remomove duplicatehide duplicate values phpremove duplicates between arraysphp remove duplicate values in arrayremove duplicate values in an array in phpphp count unique keys in arrayphp remove duplicates from array key and valuereturn type of array uniquearrau unique phpfind duplicate values phparray unique php index not getting organisedremove duplicate value from two array in phpphp array douplic value make unique get only unique values from php array uniqueget duplicate values in array phpphp remove duplicates from multidimensional arrayhw to remove duplicates in the arrayhow to remove repeated data from arraycount duplicate in array phpremove duplicate words in string phpfilter unique value from loop phpphp array unique values with key start form 0php get unique values from array of objectsphp array unique array of arrayremove duplicate values in foreach phparray unique on array column which is an array phpremove duplicate numbers phpremove duplicate value from arrayhow to remove the duplicates array from nested array phpget same data from same data list in phphow to remove duplicate array in phpimplode array with unique sysmbol in phpfunction to return all duplicate values in an array wphow to remove duplicates in an array phpphp array remove duplicatesremove duplicated from php arrayremove double values in array phparray walk php remove duplicatescreate array with unique values phpphp array clean duplicatesphp remove duplicates if 1 value is samephp delete duplicates from array by explodephp return duplicate values in arrayphp remove duplicates from stringremove duplicate value array phpphp remove doublesphp delete duplicates from arrayphp remove duplicate array fieldhow to remove duplicate values in php arrayhow to remove duplicate number in array phpfind same value in array phpremove duplicates froms string in phpdelete dublicate value in array phphow to remove duplicate value from array after push in agnualr7array unique associative array phpfixes duplicate arrays to show a single character phpcheck if there is duplicate in an array phpget all different values in arr phpeliminate duplicate elements from array phphow to remove duplicate values in foreach loop phpremove duplicate array multidimension phpfunction to check if not duplicate values exist in phpremove duplicate in array phparray key unique phpremove the repetition of array phparray unique spipget unique array phpremove dublicate from arrayphp 7 3 array uniqueremove the duplicate elements in unsorted arrayphp get unique values in arrayremove duplicate element from array without using any array function and continue statement in phpremove duplicate value from associative array in phpturn array with unique values phpphp print unique array valuesphp count duplicated arraysremove duplicates from array using reducephp remove repeated values arrayhow to remove duplicate values from multidimensional array in phpdelete repeated elements in array phpphp array unique on objectsduplicate id problem with phphow to remove repeated values in array phpgenerating unique values in phpphp array distinctfilter array php not same valuephp check if array has duplicate valueshow to remove duplicates keyand value from an array in phpremove duplicate keys from array phpphp remove duplicates from arrayphp unique values on arrayphp unique array of stringsprevent duplicate entries with phpremove dublicate array valuephp find in array how many similarunique values register phpremove array duplicate phphow to remove duplicate value from array in php 5cremove duplicated value i narrayarray unique by values phpphp unique valuesarray unique associated array phpremove duplicated from arrayphparray uniquefind array unique phphow to remove duplicates in array jsget unique values from object phphow to remove duplicate words from string in phpremove duplicate elements from arrayhow to get duplicate values from associative array in phpremove duplicate values in multidimensional array phpphp to array unique stringget the unique array keys phpcheck if a value is duplicate phpphp remove duplicate values from array case incenstivephp remove duplicates in array of stringremove the duplicate keys and merge their values in an array phpphp uniqueremove duplicate values in array javascriptselect unique from array phpremove duplicate value foreach phpphp remove duplicates in an arrayphp array distinctive valuephp function return unique values arrayarray unique php laravel7 ways to remove duplicate from arrayphp get all duplicate values in arrayfind duplicate values in array of objects phpduplicate values remove in arrayprint unique array phpremove duplicate arrayshow remove the same value from array in phpphp array collection remove duplicatesselect array without duplicate phpphp keep distinct values of array array should not store duplicate values phparray unique function in phpremove duplicates from array in javascripthow to remove duplicates from an array in phpcheck dup in array phpfind duplicate values from array in phpremove repeated values from an arrayhow to get duplicate values in array phparray value of array unique phpremove duplicates from object array phpphp unique stringremove duplicate elements in array phpphp array remove all values that are duplicatesphp remove duplicates from array base of keyjoining two arrays in php removing duplicate elementsarray distict php netmake array in array unique phpremove duplicate array javascripthow to eliminate duplicate strings in a array of strings in phpalgorithm to remove duplicate elements in an array in phpphp array unique sort flagsprevent repeat array keycount repeated values in array phpphp array unique with array of arrayremove duplicate string in array phphow to check for duplicate entry in php ooplaravel unique arrayremove duplicate elements from the array mesclar array e remover duplicates phpremove repeated elements in php associative arrayforeach remove duplicate phpphp filter doubles out of list of stringsmake array in array uniquearray of array to one unique arrayremove duplicates in in array in phpremove duplicate items array phpphp array uniqie yearremove duplicate from arratremove all duplicates in array phphow to find duplicate elements in an array in phpphp remove duplicate from array to another arrayhow to check the duplicate array values in multi dimensional array in phpphp array duplicates checkunique values of an array phphow to store duplicate value index in phpremove duplicate values from array core phpphp array of arrays duplicatesunique php formfind and get duplicates of array in phpcount duplicate in array and delete using phpphp array distinctget specific unique values from array phpcreate new array without duplicatesarray get only the value without duplicatecheck repetition in array phpphp make sure array items are uniquephp array reduce for making new array with unique valuephp array integer duplicate values make uniquephp unique associative arrayremove duplicate associative array php without change formatremove duplicate number in arrayphp check double entry arrayget unique objects from array phpdelete duplicates phpunique value phphow to remove duplicate values in array phpcount duplicate strings array phpdelete duplicates in phpadd unique value in array phpphp remove repeated from arrayhow to check duplicate object in array phpremove duplicate element in array phphow to remove duplicate value from array without using any array function and without using contnue in phpfow to remove duplicate entries in array while pushget rid of duplicates in array javascriptremove duplicate values from 2 table in phpremove duplicate value in phpremove duplicates from an array in placephp array remove double entriesphp handle duplicate value arrayphp avoid duplicate entry in arraywrite a program to remove duplicates from an array in javascriptarray marce and get unique phpremoved duplicates in arraywrite a function that can remove duplicate entries from an arrayfilter duplicate php arrayphp remove duplicates from arrayhow to unique array in phpphp function to remove duplicate values from array javascriptremove duplicate strings in array phpphp array rows remove duplicatesremove duplicates in associative array phpunique key in database phpremove duplicate array elements in placeremove duplicate values in an array during loop phpremove one from the duplicates php arraydont show which is duplicate value phpfind unique element from array in phparray without duplication laraelphp remove duplicate arrayremove duplicates in array javascriptget unique elements from array phpphp array unique sort php array get unique valuesdisplay records and with duplicate only ones phpdelete duplicate elements in array phpphp array remove duplicationsphp code for remove duplicate vvaluesremove repeated values in arrary phpremove duplicate values form arrayarray unique php in multiple array in one variablephp array delete duplicate valuesstop duplicate in phpremove the non duplicate items from an arrayremove duplicates in foreach loop phparray unique in php using a columnphp array non unique keysarray uniques phparray unique without index phpdistinc value phpa arrayless than php remove duplicates from listlaravel array uniqueunique key value array phpremove duplicate values from arrayarray unique in php without array functonarray merge duplicates phpnew uniqueness phpduplicate value remove in array in phplaravel arr uniqueunique value array phpeliminate duplicate in array phpget unique array from associative array phpphp array unique by created atfind unique elements in array php without using functionarray unique check array key level if duplicate arrays to show a single character phpremove duplicate for foreach output phpget unique array in associative array in phpdublicated id problem with phpdelete duplicate entry in arrayhow to remove a duplicate number from a list in javascriptphp array remove only duplicate values not keyshow to get unique values in php arrayreorder index array unique phpwrite code to remove duplicate from array numbersunique array value in phpcheck array for duplicate values phphow to check duplicates in array phpdelete doublon array phpphp remove duplicates from listarray unique examplesphp for each create unique arrayphp compare two arrays remove duplicatesremove duplicate key array phpcheck same and differnt value in array in phphow to remove duplicate files from array in phparray merge not remove duplicates phpfilter out duplicate values in arrayarray key sort unique laravelif duplicate value phpphp remove duplicates arrayget rid of duplicates in php arrayget unique array by phpremoving duplicates without sorting an arrayarray remove dupliactes phpphp array remove duplicated valuesremoving duplicate items from arraydedupe function jsget array unique values phpphp duplicate array removearray unique by key phparray eliminate duplicatesget repeated array values phphow can i stop a duplicate value in array phparray unique in phphow to remove duplicate elements from array in javascriptphp to exclude duplicate array value from 24 requestphp remove duplicate array valuesremove duplicates in string phpshow errorremove duplicate form arrayphp only unique values in arrayphp array remove repeated valueshow to insert duplicate values in php in an arrayphp unique array values without keyhow to remive duplicate from list phpremove duplicate array in phpfilter duplicate values phpphp make array values uniqueremove the duplicate value and plus them phpphp find array duplicate valuesphp array get redundant elementscount duplicate in phpuniq array phpkeep unique values in array phphow to get the index from array unqiue in phpphp add inside array without reapet input laravel removing duplicate from an array in phpphp create array of unique usersphp unique fields arrayphp remove duplicates from arraysphp array filter duplicatesremove duplicate from 24row 3ekey phphow to select distinct value in php arrayremove same array value phpremove duplicate values from array in php without using functionprevent duplicate entries in phplaravel unique array in arrayhow to remove duplicate values from an array in javascripthow to remove duplicates in array in php without functionshow to shift index in array after using array unique in phpunique string in array phpreturn unique elements in array in phpget duplicate value from array phpphp array remove duplicate keyphp create array based on unique valuesarray unique by value phpphp array unique values onlyfind unique elements from array without using function in phpcount duplicate values in php arrayremove similar values array phpremove duplicate data from array in javascriptarray unique php by valuearray value remove duplicate php get unique values from list phpeliminate duplicates in array phpphp array distinct specific valueremove duplicates from list phpmake unique array in phpphp remove duplicates from array phpphp remove duplicates from array in foreachget unique values phptake only unique elements in array phphow to remove repeated numbers in arrayhow to remove duplicates in php arrayarray unique for key phpremove duplicate in array javascriptfilteredduplicata phphow to remove repeated data in arrayfind unique values in array phpphp check for duplicate valuesphp array of unique stringsarray uniques phphow to remove the duplicated in arraycheck if duplicates in array phparray unique on specify value phpphp remove duplicate value in arrayhow to fill unique array in phpphp get all unique categories from sub arrayphp remove duplicates from an arrayarray only unique values phphow to find unique indexes in array in phpremove same values from array phparray eliminate duplicates phpremove duplicates value in array phpremvoe duplicates phphow to remove duplicate entries from a multidimensional array phpphp array remove doublemake array dont remove duplicate keys phparray unique by key in object phpdelete duplicates from 2 arrays phpget specific unique values from arrayphpdelete duplicates in php arrayphp check string for duplicatesphp array unique by valueremove duplicate from array php methods check old valuephp compare arrays remove duplicatesphp create unique id to array of arraysremove duplicates from associative array phpremove duplicates array javascriptstring remove duplicates phpdelete repeated elements in arrayremove duplicate values from two arrays phpphp number of unique keys in arrayhow to take only unique value in array in phpmake unique in array phpremove duplicates from php arrayjavascript remove duplicates from arrayhow to remove duplicate value from array in javascriptphp compare arrays remove all duplicate arraysphp array find duplicate valuessame array php removefind duplicate value in phpcheck if value is repeated in array phpremove duplicates from an object in phpphp array unique valucheck two number in array duplicates phpphp find duplicates in stringremove duplicate strings from array phpunique data in array using phpremove duplicates from array 2b phphow to delete duplicates in array of arraysarray only get duplicateshow to skip duplicate values in arrayphp get distinct values from arrayunique array php by valueremove duplicates from 2d array phpremove duplicate keys in array of if keys are sameunique value from array phpwhy when i want remove duplicate value in array phpis unique phparray unique php removing all duplicatesphp array find all uniqueget unique values of array phphow to remove duplicate value in foreach loop in phpphp remove leading blanksphp remove duplicate objects from arrayphp extract unique values from arrayfind duplicate values in array php without using functionremove any duplicates in an array phpphp array unique objectsremove duplicate array from parent arrayphp array check if all values are uniqueselect distinct values from a group of array phpjquery array uniquehow to removed duplicate entryin arrya phpphp array duplicatesjs array remove duplicatesphp array uniq valuesremove duplicate array keys phphow to check the only unique item in an array phpremove duplicate entries array phpremove duplicates from 2 dimentional array 2b phpphp get unique item in array phpcreating a function that removes duplicates php wihtout using array unique 28 29how to find the duplicate values in array in phpremove duplicate elements from array phpremove duplicate item in array javascripthow to remove duplicates from a collection in phpphp array integer duplicate value make uniquehow to array index duplicate remove in phpjavascript array remove duplicates itemremove duplicates from list javascriptphp remove duphp filter duplicate from arrayarray unique values phparray unique without keys phpphp array unique values getremove duplicates in javascript arrayarray unique 28 29 in phpload nonduplicates in array phpphp array unique examplein php unique value record from arraycount the number of duplicates phphow to find between two arrays and remove duplicates in phphow to find unique values in array in pharray unique values in phpphp check for duplicates values in object in arrayduplicate array phphow to remove the duplicated numbers of a given array in phpcompare new array with current and remove duplicates from new arraymake array in php uniquehow to remove duplicate id from array in phpfind duplicates in array phpphp array uniqshould take an array and return an array with all the duplicates removedarray prototype remove duplicateseleminate duplicate values from array phpconcat and remove duplicates phpremove duplicates php string arrayremove duplicates js arrayunique key generate 2b phpget unique array values phpfind the unique element in an array phpphp check if array column value duplicated in loop php check string to identical array valuedelete duplicate in array phparray find repeated number phpremove a duplicate item from the arrayremove duplicates from array phpget unique value in array phpphp create array without duplicate valuesremove dupliocates in an arrayhow to remove duplicate number in php arrayremove duplicate values from two array phpphp unique 5 numberlaravel array unique valuesremoving duplicates from an arrayphp array unique objectsphp remove element with same element in arrayarray remove duplicates and blank valueremove repeated value in associative array phpinserting duplicate values in an array in phpremove duplicates from array php with foreach loopi have multiple arrays and i want to use array unique on that in phpremove duplicate values in phpremove duplicate value from array using filterhow to remove duplicate values from arraysphp array unique stringphp remove duplicates based on conditionarray unique phpphp check unique elements in arrayremove duplicates from query params phpunique array php w3schoolsphp detect duplicates in arrayfind array unique inside array values in phpremove duplicates vaes from string in phparray unique by key phphow to remove same item from an arraymake unique array in php from keycheck duplicates in bidimension array phpeleminate duplicates in arrayarray value unique laravel arrremove from array duplicate value phpdelete duplicate values from array phpphp duplicate array values removeunique key phplaravel array ignore same valueprint array without double values phphow to remove duplicate elements in phpremove repeated values array phphow do you remove duplicates from an array in place 3fget unique values from array phpphp merge arrays remove duplicate valuesphp get duplicate values in arraymake array unique php with keyremove array value repeated in phpunique key phpphp array add unique valueremove duplicated in array phpphp filter unique values arrayarray unique for foriagne key phpremove key from array unique in phpdistinct on array phpwrite a php program to remove duplicates from a sorted list remove duplicates from an unsorted arrayhow to find the duplicate number on a given integer array phpremove duplicate array items by indexphp remove duplicates from associative arrayhow to remove duplicate objects in an array in phpphp remove duplicates objects in arraycheck for duplicates in php arrayreturn unique array phparray remove duplicatesphp unique arrayphp check array for duplicatephp table remove duplicate from arrayhow to make an array unique in phpremove duplaicete value array phphow to find non unique character in phpphp array unique nullhow to remove repeated values in array phpphp filter duplicates from arrayhow to get rid of duplicate values from an arrayhow to avoid duplicate values in phphow to remove duplicate value form arrayphp no duplicates in arrayhow to get array without duplicatesjs remove duplicate in arrayarray map duplicate keys phpunique in arrayphp make all values in array uniquecan you remove duplicates from an arrayarray unique find in phpphp identify duplicate valuesphp remove dupliactes in arraycheck in array unique data phpremove duplicates phpphp check duplicate values in arrayarray find unique values phpunique arrayhow to a distinct number in phpphp remove duplicates on arrayremove duplicate array php by index keydelete all same value from array phpphp unique keyremove all duplicate entries in array in jsremove duplicate elements from array javascriptno duplicate phpphp array filter unique valuesphp array remove duplicatehow to make a array unique in phpphp get item unique from arrayphp remove duplicates tableunique arra phpsort array and remove duplicates in php without in functionsphp array unique array of objectsphp check unique index in arrayphp remove duplicates in multidimensional arrayremove duplicates from array but remain same orderhow much time does array unique takeget only unique values from array phpphp array unique valuehow to remove duplicates in an arrayphp if duplicatephp find duplicatesphp remove duplicate values from multidimensional arrayremove duplicates from an array without using any inbuilt functions in phpphp make array unique valuesmake array list unique phpphp remove duplicates object from arrayphp array only unique valuesphp array remove duplicates valuesremove duplicate from arraycheck duplicate data in array phpfind duplicate in array value phparray unique php sued in table genrate suing sqlphp array unique without sortingarray deduplicate in phpphp remove array duplicatesphp remove duplicates from muliple arraystypescript remove duplicates from array by valueremove duplicate entry in phponly unique keys in array phpremove dupliicates from an arrayselect unique value from array phpphp remove duplicates from queryhow to count data in duplicate row in phpremove duplicates from multiple array in phphow to delete duplicate elements in an array phpphp find duplicates in multidimensional arrayphp array find duplicatesphp delete duplicates idarray sort unique laravelremove duplcates from an arrayremove duplicate data in array phpaccess unique keys in array phparray remove same valueremove all duplicates in an arrayphp sort uniquehow to remove duplicates in an array javascriptmongodb remove id from arraycheck duplicate records in an array using phpphp remove duplicite array keyshow to make array unique in phpremove repeated interger in an arraycheck array for duplicate key value phpget unique values from array of objects phpget unique key name from array phpphp array unique number of elementsremove all duplicates from arrayhow toremove dublicate value from arrayremove all duplicate key value from array phpremove duplicates from images array phphow to remove same value in array in phpunique array elements phpunique data in array phpfilter only unique string in phpsave in array duplicated text in phpjavascript list remove duplicateshow to remove same number from arrayfind duplicate and count duplicate elements in array phpphp remove duplicates from multidimensional array by valueget the unique value from an array in phpphp set unique valuesget unique values in array phpphp find duplicates 3dphp add to array without duplicatesarray unique returns objectphp array unique keyget unique values from associative both key and value array phpjs remove duplicates from array set unique arrayphp check if value duplicate in columnarray unique trong phpphp get duplicate value rowjavascript array eliminate duplicatesduplicates removed from an array without using any inbuilt function in phpremove duplicated values from arry jshow to remove same values from array in phpwrite a php a function to remove a specified 2c duplicate entry from an array remove duplicates php from arrayhow to remove duplicates element from array of array in phpphp array value uniquedistinct values array phpphp unique objects in arrayhow to select only distinct value in array in phpphp array remove duplicate array with same valueremove duplicates elements in arraylisremove duplicates from arrayremove duplicates from array and also check if there is duplicate or notfind unique values in array php by keyunique array phpphp eliminate duplicates from arrayhow to generate unique key in phparray unique without array keys in phphow to separate duplicate items in an array phpunique array php with keep typeremove any duplicates in array jsremove dupliactes from an arrayfilter array for duplicates phpsort array and remove duplicates in phpsoring an array and removing duplicatesphp remove duplicate object values from arrayphp get unique array from setremoving duplicate from array in javascriptduplicate values in array phpget number similar value in array phpfind duplicate values in array phphow to get unique id every time in phphow to check for a repetition of elements in an array using phphow to find unique numbers in array phpfind duplicates in associative array phpremove repeating elements in array phpwhat is unique in phpphp remove duplicate value from arraydo keys need to be unique in php arraysarray unique based on key phphow to get unique array value in phpexclude all the duplicate value in an arraysame value remove in array phpunique value in array in phphow to remove duplicate values from a array in phpremopte duplicate phpget unique element from an array phphow to remove duplicate values from array in javascripthow to remove duplicates from array in javascriptjs remove array duplicatesarray remove repeated values phpremove duplicate by key phphow to avoid duplicate records in phpremove duplicate array vallues phparray merge and remove duplicates phphow to prevent duplicates entry in arrayfind unique value php methodremove a duplicates from arraydelete repeated elements array phparray delete duplicates jphphow to remove duplicate values from an array in phpeliminate duplicate letter in array phpadelete dulpvcate aray phpduplicate item remove from index array in phpdelete duplicate elements array phpphp array delete duplicatesdelete duplicate sql with phpremove 22duplicate arrays 22 multidimensional phpjavascript array remove duplicate valuesarray duplicate in phpremove the same value in array in phpfunction to remove duplicate elements from the arrayget unique values from array in phparray unique record in phpremove duplicates number based on another column name phpremove duplicate values from array phphow to remove duplicates from an arrayarray sort unique laravelphp exclude duplicates arrayarray unique objectcount duplicate elements in array phpdelete all duplicates find single array phparray unique value in phphow to remove duplicate value from string in phparray unique php array in arraycount duplicates phpremove duplicate value from string in phpphp for loop remove duplicatesremove duplicate value in multidimensional array phpphp array distinct keyremove duplicates in array in phpphp remove duplicates from array by key valuephp remove duplicates from array if one of the values are samephp array get rid of duplicateonly different values array phphow to check value duplicate array in phphow to find unique array values in phpprint unique elements in array phpprogram to remove duplicate value from array jsphp make array uniqueremove duplicate value to array pushhow many ways to delete the duplicates inside the arrayto remove duplicate element in arayremove same value arrayphp code to prevent duplicate entrieshow to remove duplicate values in from a array list on specific elelemt in jsphp remove duplicates from array by keyphp duplicate valueif duplicate entry phparray find unique key phpdelete dulicate item in arrayphp find duplicates in array and removeremove duplicates array phphow to delete repeated elements in arrayphp get unique values from objuect arrayissues with array unique phpphp array duplicatedelete repeated element in array phpcheck for duplicate values in array phpphp array get duplicate valueshow to check duplicate data in phpphp array uniquesarray unique value phpphp remove duplicates in arrayphp make sure values in array are uniquephp remove duplicate keys from arraycheck duplicates in php stringget all unique values in a javascript array 28remove duplicates 29associative array in one key in value must unique in array check in phpget unique array in phpremove duplicate data from arrayarray merge with unique values in laravel collectionarray remove repeated dataarray remove duplicates from array phparray unique value phphow to remove duplicates from php arrayhow to check duplicate in an array phpphp array unique value arrayarray unique object phpphp remove dupolicate arrayhow to remove duplication from arrayhow to check repeated values in array using phpfilter duplicates in php array delete duplicates from arrayhow to delete duplicates in foreach in phpcorrect key values in array php after array uniqueget rid of duplicates phpthe array unique 28 29 function removes elements that are unique to an array remove duplicates and add all values to different array phparray without duplicates phphow clear repeat value in array in laravelhow to remove duplicates in array phphow to remove element from a unique array in phpremove duplicate string in two array phpremove duplicate from array by idununique php array examplearray unique changelogphp count unique values in arrayarray unique php associative by valueremove duplicates from array jsremove duplicates from array only once javascript using filter looparray distinct phparray of unique value phparray unique phphow to remove duplicate array value in phpphp filter unique arrayget duplicated value phpremove duplicates from an arrayremove duplicate array value in phpphp get repeated values in arraynested array remove duplicates in phpremove duplicates from oarray phpbject array phpremove all the duplicates from an arrayremoving duplicates if exists in an arrayhow to check duplicate array in phpget unique value from php arrayremove duplicates in array phparray uniqueseparate duplicate values in array phparray values 28array unique 28php array get repeated valueshow to remove duplicate element from array in phpfilter duplicate array from array list with value in phpphp count array duplicatesphp get unique values from array without generating keysphp remove duplicateremove same values in arrayhow can be remove repeated data in array phpcount the value of duplicate key phpremove duplicate value from array query phpphp distinct arrayarray values key with unique phparray php unique valuephp array helpers unique valuesremove duplicate in nest array phpphp associative array unique valueshow to remove duplicate number in phpremove duplicate array using array key in phpwhat does array unique returnhow to remove duplicates element in array phpdelete the same value in array phpremove duplicates from string in phpprint duplicate values in array phphow to find duplicate data in array in phpassociative array php remove duplicatesremoving duplicates in array javascriptphp echo unique array itemsphp array function duplicate in arrayphp check for duplicates in listcode for remove duplicate from arrayphp remove duplicates from multidimensional array by key valuearray unqiue phpphp remove duplicates from array by key valuejs remove duplicates from arrayduplicate checking phpfind unique elements in phpremove duplicate item in array phpremove duplicate index array phpphp array with unique subarraysarray unique without keys in phpremove duplicate array in an array in phpphp array key value uniqueforeach and create array unique phpeliminate duplicates while looping phpphp array unique opositearray unique associative array phpphp remove duplicate from arrayphp find duplicate key value in arrayphp create array of unique valuesremove duplicate in an array in php without using functionhow to get list of distinct elements from list phpfind unique value in array php methodcheck no duplicate string in c 23 arrayphp remove redundant arrayremoving duplicates in an array in jsphp display array values using unique valuehow to find repeated elements in an array in phpphp user defined function to remove duplicate from an arrayhow to submit unique value in database using phphow to avoid duplicate query in phpdelte unique values in phpremove duplicate value foreach php by title variablehow to count duplicate values in array in phpremove duplicates of array in phphow to avoid duplicates in arrayremove duplicates from array python 3javascript remove all duplicates from arrayphp remove duplicates from number array remove php duplicateshow to remove the duplicate keys from an associative array phpphp find duplicate array valuesfind number that dont have duplicate in phpunique element in array helper phpunset duplicates phpmake number of duplicate elements in array phpremove duplicate and trip array phpphp remove duplicates from while loopobject unique by keys phploop avoid duplicates phpreturn 1 value from array if duplicate value phpphp remove duplicate words from stringget disting element of an array phpunique key in array phpremove duplicate from array in phpremoving duplicates from an array phpremove duplicate entries multidimensional array phpremove duplicates mutiledemention array phpremove duplicates from sorted array php remove duplicate s from an arrayhow to read array unique phpphp display unique values on arrayarray filter duplicate values phpremove duplicate entery from array in phpcheck duplicate value in array laravelreturn unique value in array phpphp get duplicate entries in arraystop duplicates going to arrayphp array eliminate duplicatesarray no of duplictae items phpfinding duplicates in an array phparray unique with unique key phphow to remove dupilicate items in arrayremove all duplicates from associative array array phpcheck duplicate records in an array phphow to make array of distict value from the list of objects using phpdelete same value in array phpremove duplicate value from array in phpunique elements in array phpstop pushing duplicate array value in phpphp serach for uniqueunique value from array in phparray duplicate remove in phpphp array without duplicateshow to use unique array in phpmake unique by array phphas duplicate values phpremove duplicate data in two arrays phpnode js array remove duplicatesremove null values and duplicate from array phpphp unique value in arrayarray unique from first array phpphp array unique objects valuestop duplicates when adding to an array in phpphp unique array obectsfunction to find duplicate elements in an array and return its keys in phpfind duplicates and remove 1 in an arrayphp unique array based on keyarray how to remove duplicate arrya in phpreturn 1 value if duplicate phparray unique in phpremove duplicates in associative array based on key phpreturn 1 value from array if duplicates value phparray unique for associative array in phparray unique with new key phpmy php unique keyunique in array phphow to remove duplicates in arrayhow to remove dupliacte array in phpunique value in array phpremove duplicates from an array in phpdont unique array phphow to get duplicates array in phpwrite program to remove duplicate values from array in phpphp duplicates in arrayhow to remove duplicate veribales in a array phpphp show unique array valuesarray key unique timestamp phpremove duplicate value inside foreach phpphp foreach create unique arrayhow to detect duplicate number in phparray merge unique fieldeliminate duplicate values from associative array phphselect an item from array using a unique value phpmakey value unique array phpphp remove duplicates fro arrayphp array remove duplicate array with same key valuearray find duplicates phphow to remove duplicate value from arrayget unique values from a php arrayget the sorted list for db in laravel without duplicationdelete duplicate object in array phparray unique in array of object phparray values unique phpphp find unique values in arrayphp how to remove duplicate values from arrayremove duplicate value from array laravelphp get arry of unique indicesremove duplicate parameters in phphow to remove duplicate array values in phpjavascript array remove duplicatephp array unique convert to arrayquit all repeated values in array phpphp get rid of duplicates in arrayhow to remove duplicates from array phpphp array delete double valuesphp check repeated in arrayremove repeated elements in array phpremoves duplicate elements from an array find the number of times a string is repeated in an array in phpphp distinct values in arrayphp array get uniquearray unique phphow to remove dulpicate in array in jshow to get array with inside array of duplicate rowsdelete duplicates in array phponly unique values in array phpphp array double valuedelete duplicates on foreach loop phpphp array keep only unique valuesdo php array keys have to be uniqueduplicate value remove array phpremove duplicate elements from array in phphow to get array with inside array of duplicate rows laravelget unique objects in array phpphp array unique array valuesuniquie arrayhow to remove duplicate price in php arrayunique associative array phpphp select unique values from arrayif duplicate in phpremove duplicate particular ley 27s value from array phparray uniqe phpremove the duplicate from an array phpremove duplicates in arrayeliminate duplicate characters in array phpphp check associative array unique by two fieldstake a unique records phpdeduplicate array by value phphow to get duplicate in an array using phparray unique in php by specific key valuehow can set unique in phpconcat arrays and remove duplicate from itremoves duplicates form arryget unique values from object array phparray unique in angularphp get unique items in arraycheck if a array value is duplicate phparray unique in laravel collectionphp return unique values arraydifferent elements of array phphow to remove duplicate values from an object in phpuse array with duplicates phparray unique php with keyunique array in phpjavascript function remove duplicates arrayhow to get unique key value form array in phphow to remove duplicates from array in phpdelete duplicates preserve 1 in an array phpphp array unique without keysshow array with unique values phpfunction to delet the uncommon values in phpfind the duplicate number on a given integer array phpremove duplicates values in array php c3 b9nique value php arrayremove duplicate id array phpfind duplicatew in array phphow to remove duplicates in arrays in loop phphow to remove duplicates in a php arrayphp array of unique valuesget duplicates value from array phpgenerate unique key by string in phparray unique php by keyfilter duplicate entries in array phphow to remove duplicate values in array in phpdelete all duplicates array phphow to get unique values only from an array in phpremove duplicate in array of array in phparray repeated values phpphp array uniqueremove duplicate value in list phpeliminate duplicates in an array javascriptremove duplicate records from array phpfind the number of times a string is repeated in a array in phpfind similar values in array phpmake array unique phphow to create unique key in phpremove dup phparray unique in php for one valueremove duplicates from unsorted arrayphp get all unique values from arrayphp select all duplicate word in arrayphp unique array by valuephp remove duplicates from dictionaryget unique values in phpremoving duplicates from php arrays nestedarray duplicate by value remove phpphp filter unique value of other arraymake associative array unique phpphp remove all duplicates from arrayarray unique ppduplicate phpunique array into php the best way to remove duplicates from an arrayphp associative array unique by two columnfunction to delete the common values in phpphp array to setduplicate values from an array in phphow to remove duplicate value from array in phpphp check duplicate value in arraywhy array duplicate same valuehow to remove array duplicates in phpunique 28 24array 29how to remove duplicates in a php array without a build in functionphp duplicate array itemremoving duplicates from an array php user defined functionphp unique array valuesreomove duplicates in php in arrayphp unique key from classremove array duplicates phparray unique 28 29 on value phpremvoe dup from array phpunique values phparray unique 28array columnremoving duplicate items in phpphp delete duplicate values in arrayremove the duplicate elements in array php remove duplicate values in array phpremove duplicte array elementseliminate duplicates array phparray unique with key phpretool duplicate values in arrayremove duplicate value foreach phphow to remove the duplicated numbers array in phplaravel array uniquephp array values uniqueremove duplicate values from array in phpremove uniue value in php arrayphp get array unique valuesphp detect duplicates valus in arrayphp array unique keysremove duplicate particular key 27s value from array phpphp remove duplicates bidimensional arrayfilter array if duplicates phphow to get only unique value from array in phpremove duplicate array value phphow to remove duplicates from a list in phpdelete duplicatte in array phpphp filter array with same valueremove duplicates in array php 7php get array of unique indicesremove duplicates in array of arrays who have same key phphow to use unique with arrays phpphp array unique by keyphp find duplicates in arrayphp find duplicated array valuesget array of values withou duplicationremove duplicates from trhidimensional array phpremove duplicates in multidimensional array phparray remove duplicates phpremove duplicate value from array phparray unique sort regular phpdetermine exact same array in phpphp filter unique valuearray remove duplicate values phpremoving duplicate element from array using includes methodarray unique php