Replace string key of PHP array
- by poru
Hello,
I have an array in PHP which looks like that:
$test = array('3' => 5);
How could I replace the stringed array key 3?
I tried:
$test['3'] = "New value"
but it don't work, it look like that after that:
array('3' => 5, 3 => "New value")