First I would like to say, great module! It was exactly what I was looking for.

When the maximum upload size per file is left empty, FUpload allows files of any size to be uploaded. If the file exceeds the php upload limit, an “Upload failed:” error is generated with no additional details and dblog contains an entry “implode() [function.implode]: Invalid arguments passed in usr/www/users/ucpclass/sites/all/modules/image_fupload/image_fupload.module on line 206.”.

The root of the implode bug appears to be when the $_FILES['files']['error'] flag is set. The file_save_upload() function, in drupal core, utilizes drupal_set_message() to display the error and not form_set_error(). Patch to follow, it’s not a complete fix, as IMHO the file size check should occur before upload, but will allow for the error details to be added to the “Upload failed” message and prevent the exception with the call to implode.

CommentFileSizeAuthor
#1 image_fupload.patch1.58 KBc.d.a
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

c.d.a’s picture

FileSize
1.58 KB

As promised.

grasmash’s picture

Wow, thank you! I could not figure out how to fix this for the longest time... I even have my php upload variables set?

pico34’s picture

Excellent patch, it brings me the right message, my problem was about a 'upload_max_filesize' too small.
Theses lignes added in my .htaccess file and it works :) Thanks

php_value upload_max_filesize 8M
php_value post_max_size 8M