Source Code:
(back to article)
<?php $array = ['a', 'b', 'c']; $newArray = array_combine(range(1, count($array)), array_values($array)); print_r($newArray);
Result:
Report an issue