Well, that's an interesting point, and negates my previous comment.
Since I'm starting with $form[$var] = array( I won't have any
artifacts from the original field, will I? So wouldn't the field then
be composed of only those two parameters, #type and #value? That should
be all it needs. Changed it to 'value' from 'hidden', unfortunately
there was no side benefit of correcting it.
When I change it from $form[$var] = array( to $form[$var]['#type'] =
etc. I no longer get the from, but get the error Only variables can
be passed by reference
Jeff
On 6/28/2010 10:57 AM, Steve Ringwood wrote:
Whats the value of $var?
Because it's a CCK field you may need to use
$form[$var]['#type'] = 'hidden';
$form[$var]['#value'] = $nid;
to avoid clearing elements CCK expects to find.
(Side note: I would use 'value' instead of 'hidden')
Nevets