note 23483 deleted from function.array-pad by jsheets

From: Date: Sun, 23 Mar 2003 23:29:50 +0000
Subject: note 23483 deleted from function.array-pad by jsheets
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-45704@lists.php.net to get a copy of this message
array_pad() works ok for the above given example. But, it will do the following: $myArr = array(2 => 'three', 3 => 'four'); $newArr = array_pad($myArr, 4, 'FILLED'); // this will output Array ( [0] => three [1] => four [2] => FILLED [3] => FILLED ) // but one would like this to do: Array ( [0] => FILLED [1] => FILLED [2] => three [3] => four ) May be its a bug?

« previous php.notes (#45704) next »