I need to count the number of times a value has a value in a given array.
For instance:
$array = array(5, 5, 2, 1); // 5 = 2 times // 2 = 1 time // 1 = 1 time
Is there such a function? If yes, tell me this in php docs ... because I cannot find it.
Thanks.
source share