I have for cycle
and there I create an array of names from the list, and what I need to do is remove duplicate values, then I get this array:
Array ( [0] => Tod [1] => Admin [2] => Tod )
$c=count($_SESSION['cart']);
$list_array = array();
for($i=0;$i<$c;$i++){
$id=$_SESSION['list'][$i]['id'];
$person=get_person($id);
$list_array[] = $person;
}