Re: add item to end of (multidimensional) array

From: Date: Fri, 15 Oct 2004 12:45:54 +0000
Subject: Re: add item to end of (multidimensional) array
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-199584@lists.php.net to get a copy of this message
try $Arr[] = array('name' => 'arnold', 'address' => 'street'); Arnold wrote:
Hi, How can i add new items to an array without using an index. Normally (single dimension) you can do: Arr[]="xxxxx" and this item is added to the array, but what if i have subitems like: Arr[]['name']="arnold"; Arr[]['address']="street". This last example doesnt work and i think there will be an easy solution but who can tell me this? Arnold


« previous php.general (#199584) next »