hello, I'm trying to create a new content which use an ImageField, and I get this error:

warning: in_array() [function.in-array]: Wrong datatype for second argument in /opt/lampp/htdocs/drupalportal/modules/filefield/filefield.module on line 289.

I'm new to submitting this kind of things, could you please help me to supply the information you need?

thank you

PS: I posted this issue in the wrong section (CCK), so please ignore http://drupal.org/node/315768 , sorry

Comments

fracti0n’s picture

the same here...

drupaloo-1’s picture

same here two .........
The content I created has been blown away after I added an image field to a CCK content type

brmassa’s picture

Assigned: Unassigned » brmassa
Status: Active » Needs review

Darrel,

on filefield.module, line 285: change to:

  if (isset($form['#validate']) and !in_array('filefield_node_form_validate', $form['#validate'])) {
    $form['#validate'][] = 'filefield_node_form_validate';
  }
  if (isset($form['#submit']) and !in_array('filefield_node_form_submit', $form['#submit'])) {
    $form['#submit'][] = 'filefield_node_form_submit';
  }

it fixes the message coz it checks if the $form['#submit'] and '#validate' exists first...

regards,

massa

blackdog’s picture

Status: Needs review » Closed (duplicate)