Trying to do a loop with a counter. It is necessary to make a schedule of the number of bans on the time of unix, I decided to do this:
while ($result = mysqli_fetch_assoc($query_sb)) { $data[] = date('d', $result['created']); } for($i = 0; $i < 1000; $i++) { if($data[$i] == NULL) {break;} $cnm = $i -1; if($data[$i] == $data[$cnm]) { $cntbans[$i][$b++]; } else { $b = 1; $cntbans[] = $data[$i]; } } print_r($cntbans['14']);
But how can I derive the second array "number of bans" from $ cntbans ['Day'] ['number of bans']
PS Days are already recorded in the form 16,16,16,16,17,17,18,18,19,19 ...