2024-05-12 17:35:03
循环数组,用in_array()判断是否存在
$arr = Array
(
[0] => Array
(
[0] => 330056250
[1] => 王正峰
[2] =>aaaa-
[3] => 2015-04-18
[4] => 2016-04-18
[5] => 4
)
[1] => Array
(
[0] => 330061418
[1] => 薛宗福
[2] => bbbb-
[3] => 2015-04-18
[4] => 2016-04-18
[5] => 4
)
)
foreach($arr as $key = > $val){
if(in_array('330061418',$val)){
print_r($val);
}
}
2024-05-12 15:33:59