There is a function especially for this purpose (ironically) that preserves the keys while sorting in descending order, it's called arsort();
arsort($array);
Output
Array
(
[aaa] => 3
[sss] => 2
[taf] => 1
[789] => 1
[bbb] => 1
)
The problem with array_multisort()
as it states in the documentation:
Associative (string) keys will be maintained, but numeric keys will be re-indexed.