Adding to the next element in a multidimensional array


Posted on 16th Feb 2014 07:03 pm by admin

Hi, I'm trying to add a value to $node->field_spaces['nid'] where x is the next available spot in the field_spaces array. Always adding to the next spot. I'll be calling this in a for loop to add things in there... Can anyone offer a hand?

$node->field_spaces (array)
$node->field_spaces[0] (array)
$node->field_spaces[0]['nid']

Thank you

No comments posted yet

Your Answer:

Login to answer
193 Like 29 Dislike
Previous forums Next forums
Other forums

AutoChoosing a CSS file based on URL
Hey everyone,

I have a site that has multiple URLs and CSS files.

Based on the URL tha

Undefined variables
hi
----------------------------------------------------------------------------------------------

BB_Code error
I'm having a problem with a custom built function and keep getting this error:


Warning: M

ME54/ME54N Conditional check for Release of PR
Hi Gurus,

My requirement is to put a check on the release of the PR with respect to the c

Help with php code
Hello, can anyone tell me why this php word trap fails to work,
and the trigger words get blow r

SCO Unix
I know this might not be the place to ask, but, can anyone tell me if SCO Unix comes with PHP built

Problem!
I have another problem, when i run this code i get this error "Parse error: syntax error, unexp

Undefined offset when using a flat file with pipe symbols
Hi, I've got a flat file/text file which I'm currently using as a member database for my site (not a

Displaying image from database
Hi,

I've got a site where that's got a database behind it. Currently it has loads of items in

bit of help needed
Im about to sort out my registration page for my website by customising a "registration" s

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash