I am trying to sort an array based on the `key=>value` but I can't get this done. Here is the code I am working out:

```
$arr = [
    '183034' => 9,
    '183033' => 6,
    '183032' => 3,
    '183002' => null,
    '182973' => null,
    '182971' => null,
    '182969' => null,
    '182999' => null,
    '182997' => null,
    '182995' => null,
    '182962' => null,
    '182948' => null
];

$arrTemp = [];

foreach($arr as $key => $value) {
    $arrTemp[$key] = $value;
}

array_multisort($arrTemp, SORT_NUMERIC, $arr);

var_export($arrTemp);

```

The output is:

```
#php test.php
array (
  0 => NULL,
  1 => NULL,
  2 => NULL,
  3 => NULL,
  4 => NULL,
  5 => NULL,
  6 => NULL,
  7 => NULL,
  8 => NULL,
  9 => 3,
  10 => 6,
  11 => 9,
)

```

But I expect something like:

```
array (
    '183002' => null,
    '182973' => null,
    '182971' => null,
    '183032' => 3,
    '182969' => null,
    '182999' => null,
    '183033' => 6,
    '182997' => null,
    '182995' => null,
    '183034' => 9,
    '182962' => null,
    '182948' => null    
);

```

Where value define the position where the item should be moved on. In other words let's take an example by words: `'183032' => 3` this item is holding position 3 on the result array so what I should do is keep the same array order but move that item to position 3 as you may notice on the output array. Same for `'183033' => 6` where this one holds position 6 so I reorder the whole array to move this to position 6 and so on. Can any give me some help?

**UPDATE**

What about if I change original `$arr` into this: 

```
$arr = [
    '183034' => ['sort_position' => 9],
    '183033' => ['sort_position' => 5],
    '183032' => ['sort_position' => 3],
    '183002' => [],
    '182973' => [],
    '182971' => [],
    '182969' => [],
    '182999' => [],
    '182997' => [],
    '182995' => [],
    '182962' => [],
    '182948' => []
];

```

Is almost the same but this is how the array should look (just an example) and arrays with `[]` should have other keys inside I just don't write them here because the relevant is `sort_position`.