The array to be empty is now 206 records, some of which are empty. When all the records in a record are empty, the record with this submark will be released (you can judge all, or there is a special subscript here. if the status is empty, this record will be empty, for example, array [1] means that all elements are empty)
$ Countarr = count ($ newplayer );
For ($ I = 0; $ I <$ countarr; $ I ++ ){
If ($ newplayer [$ I] ['status'] = ''){
Unset ($ newplayer [$ I]);
}
}
Poor
Reply to discussion (solution)
I forgot to say thank you. thank you first.
'; Print_r ($ arr); foreach ($ arr as $ key => $ val) {$ num = 0; foreach ($ val as $ key1 => $ val1) {if (empty ($ val1) {unset ($ arr [$ key] [$ key1]) ;}else {$ num ++ ;}} if ($ num = 0) {unset ($ arr [$ key]);} else {sort ($ arr [$ key]) ;}} sort ($ arr ); print_r ($ arr); echo'
';?>
I don't know if the landlord wants this effect. the new guy just played in this community. let's talk about it.