Remove duplicate values from an array:


SUBMITTED BY: henry1874w

DATE: June 26, 2017, 4:56 p.m.

FORMAT: Text only

SIZE: 84 Bytes

HITS: 242

  1. <?php
  2. $a=array("a"=>"red","b"=>"green","c"=>"red");
  3. print_r(array_unique($a));
  4. ?>

comments powered by Disqus