时间:2021-07-01 10:21:17 帮助过:2人阅读
$x1=array(1=>111,2=>12,3=>3333);
$y1=in_array(12,$x1,true);
echo $y1;
echo "\r\n";
$x2=array(1=>111,2=>12,3=>3333);
$y2=in_array('12',$x2,true);
echo $y2;
echo "\r\n";
$x3=array(1=>111,2=>12,3=>3333);
$y3=in_array("12",$x3,true);
echo $y3;
echo "\r\n";
?>