note 4136 modified in array_push by ronabop
| From: | ronabop@php.net | Date: | Sun, 03 Sep 2000 09:39:17 +0000 |
| Subject: | note 4136 modified in array_push by ronabop | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-4003@lists.php.net to get a copy of this message | ||
If you want to add a element to a linear table (one dimensional) the traditional method is best.
$array_name[]=$variable_name
On the other hand if you want to insert a
($key,$val)
into an array the easy way is
$array_name[$key]=$val
Thats all.
http://www.php.net/manual/function.array-push.php