To get the unique values in an array: array_unique() function
<?
$countries= array('Germany' => 'German', 'France' => 'French', 'Spain' => 'Spanish');
$languages = array_unique($countries);
printf("%s,", var_export($languages, TRUE));
?>
Related examples in the same category