Here's my array:
[a] => apple
[b] => banana
[c] => Array
(
[2] => x
[4] => y
[6] => z
)
I'm looking for a way to put my [c] array variables in "order". Making my array, look like this:
[a] => apple
[b] => banana
[c] => Array
(
[1] => x
[2] => y
[3] => z
)
Is there a way to do it without creating a new function by myself?
sort($a['c'])(assuming your array is stored in the$avariable).$a['c']are already in order. Is it important to have their keys starting with1?