How to rearrange the array element from 0th index in the sequence to end in PHP?
UPDATED
I have an array:
$input =array{
2 => '13234390',
4 => '12345290',
5 => '21322210'
}
now I want this array to be rearranged as
$input =array{
0 => '13234390',
1 => '12345290',
2 => '21322210'
}
With
array_values()
returns all the values from the input array and indexes numerically the array.Example:
$array = array_values($input);
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With