Hello!

I'm using the cvs version of drupal.
I downloaded the cvs version img_assist module as well as the cvs version formupdater module and I have an error in the file system.module.

Here the error:

Fatal error: Cannot uses string offset have year array in/home/valerie/public_html/drupal4/modules/system.module one line 734.

With this code:

function system_settings_form($form_id, $form) {
$form['buttons']['submit'] = array('#type' => 'submit', '#value' => t('Save configuration') );
$form['buttons']['reset'] = array('#type' => 'submit', '#value' => t('Reset to defaults') );

if (!empty($_POST) && form_get_errors()) {
drupal_set_message(t('The settings have not been saved because of the errors.'), 'error');
}

And line 734 is:
$form['buttons']['submit'] = array('#type' => 'submit', '#value' => t('Save configuration') );

Can you say to me what I must do to cure it?

Please, help me because I need some for my project for training course.

Thank you in advance.

Comments

pol’s picture

Sorry I can't help you, try to contact the author of the module directly maybe...

-Pol-

syawillim’s picture

If you cannot provide any help then perhaps don't respond.

www.slickfish.com.au
professional, affordable web site design, production and maintenance for small business

mgifford’s picture

I'm getting a similar error when I try to upload a file:

PHP Fatal error: Cannot use string offset as an array in /home/dm7_test/modules/filter.module on line 835

No solution yet. Also using the cvs version.
--
Mike Gifford, OpenConcept Consulting
Free Software for Social Change -> http://www.openconcept.ca

benwei’s picture

Yeah, I'm getting this too, with a fresh & clean CVS installation. It looks like it's associated with the patch submitted to fix this bug concerning validating form input.

If many people are getting this, perhaps that bug should be reopened or a new issue report filed.

I got it to work by commenting out line 805 from the patch, in filter_form():

//'#validate' => array('filter_form_validate' => array()),

But of course this will cause a regression on the above bug. I don't understand the forms system well enough yet to figure out a real fix for this, does anyone else?

benwei’s picture

I created an issue and a patch at http://drupal.org/node/53899.

However, upon further testing it appears that the problem is not with filter.module, but rather with event.module. I presume the same is the case for whatever file upload module you are using.