Sorry about that, accidentally submitted that in the middle of editing it.. Here's all of it.
$myArray = array ("what", "what", "do", "what");
$matchValue = "what";
$matchCount = sizeof(array_intersect ($myArray, array($matchValue)));
$matchCount will equal 3 in this example.