private static function countWhere($value = 1, $operator = '==', $conditional = 1)
{
$array = is_array($value) ? $value : (array) $value;
$operator = !in_array($operator, array('<', '>', '<=', '>=', '==', '!=')) ? '==' : $operator;
$i = 0;
foreach ($array as $current) {
$match = null;
eval('$match = (bool)("' . $current . '"' . $operator . '"' . $conditional . '");');
$i = $match ? ++$i : $i;
}
return $i;
}