Get keys from associative array [duplicate]
PHP Snippet 1:
Array ( [7] => 12 [5] => 11 [4] => 11 [2] => 9 [8] => 7 [1] => 6 [3] => 6 [6] => 5 [23] => 3 [31] => 2 [32] => 0 [30] => 0 [29] => 0 [21] => 0 [24] => 0 [22] => 0 )
PHP Snippet 2:
$arrayEquipas = array_keys($arrayOrdem);
PHP Snippet 3:
array (size=16)
0 => int 7
1 => int 5
2 => int 4
3 => int 2
4 => int 8
5 => int 1
6 => int 3
7 => int 6
8 => int 23
9 => int 31
10 => int 32
11 => int 30
12 => int 29
13 => int 21
14 => int 24
15 => int 22