array_count_values() returns an array using the values of the input array as keys and their frequency in input as values
<? $array = array (1, "hello", 1, "world", "hello"); $a=array_count_values ($array); // returns array (1=>2, "hello"=>2, "world"=>1) while ($b = each($a)) echo $b[0]."=>".$b[1]." "; ?> -- Best regards, George Nicolae IT Manager ___________________ X-Playin - Professional Web Design www.x-playin.f2s.com "Daniel alsén" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Hi! > > How do i echo the return values of array_count_values? > > Regards > # Daniel Alsén | www.mindbash.com # > # [EMAIL PROTECTED] | +46 704 86 14 92 # > # ICQ: 63006462 | +46 8 694 82 22 # > # PGP: http://www.mindbash.com/pgp/ # > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]