I try pretty much everything, read trough whole php.net and I can't seem to find a way how to get array of all keys that have the same value.
For example this is array:
Array
(
[869] => 87
[938] => 89
[870] => 127
[871] => 127
[940] => 127
[942] => 123
[947] => 123
[949] => 75
)
Array we want in my case is:
Array
(
[1] => array
(
[1] => 870
[2] => 871
[3] => 940
)
[2] => array
(
[1] => 942
[2] => 947
)
)