php 检查该数组有重复值

if (count($array) != count(array_unique($array)))

{ echo '该数组有重复值'; }

原文地址:https://www.cnblogs.com/bk7788/p/7127609.html