Hey all,
I am having one heck of a time wrapping my mind around pushing new array elements into a multidimensional array.
I have an array setup:
$results = array (
array (
ID => "0",
site_name => "site 1",
state => "AA",
URL => "http://url.com",
numbers => array (
S1_num => "12",
S2_num => "10"
),
Contact => array (
First => "Bob",
Last => "Smith",
Email => "bob_smith@yahoo.com"
),
Type => "1",
UserName => "username",
Password => "password"
)
);
and I want to be able to push in new results from a DB query. I've been reading and from what I can find array_push(); should be able to get the job done. but I am not sure if I have to push data into each array dimension at a time and then push those arrays into my main array. Any help with syntax would be greatly appreciated.