Hi there,
I'm using filefield_image with cck on a production site on a model application. Anonymous users come to the site, apply to be a model, and upload photos to the form. I'm having one incredibly weird problem that I can document, and reports of another REALLY weird problem from some users:

1. When deleting an image, I get an "An HTML 0 error as occured" message that, after I click OK, spits me out to the form as if I've it the main submit button the entire form. I've googled the hell out of that HTML 0 error and there's a ton of posts about it all over drupal.org in different modules, with no resolution :(

2. Users who are testing the form are telling me that after they clear their browser cache and return to the form to to upload more photos, they find other people's photos already uploaded into the form. As in, the filefield image widgets are populated already, with the photos of other users who have already filled out the form!

This is madness and my testers are telling me that they're experiencing this across different types of browsers, though i haven't been able to recreate the 'other people's photos' thing myself.

Any insight would be greatly appreciated! If I can't get this sorted I'm going to have to roll the whole thing back to Drupal 5 and imagefield :( :( :(

Thanks!
-elly

CommentFileSizeAuthor
#8 Picture 1.png29.79 KBelly

Comments

elly’s picture

Title: All kinds of really insane issues - jquery session problems? » Two different really weird issues
elly’s picture

Title: Two different really weird issues » problems with filefield and anonymous users

Well, I tried disabling filefield_image entirely and just using filefield, and I'm still getting the HTML 0 error.

I also thought I should try upgrading to Drupal 6.3 and its new version of jquery, but when I did, now when a file is uploaded, Drupal spews this:

{ "status": true, "data": "\x3cdiv class=\"ahah-new-content\"\x3e\x3cdiv id=\"filefield-field-photo-0-form\" class=\"filefield-field-photo-form filefield-file-form\"\x3e\x3cdiv class=\"filefield-file-edit\"\x3e\x3cdiv class=\"filefield-file-edit-flags\"\x3e\x3cspan class=\"submit-wrapper\" id=\"edit-field-photo-0-flags-field-photo-0-delete\"\x3e\x3cinput type=\"submit\" name=\"field_photo_0_delete\" id=\"edit-field-photo-0-flags-field-photo-0-delete\" value=\"Delete\" class=\"form-submit\" /\x3e\x3c/span\x3e\n\x3c/div\x3e\x3cdiv class=\"filefield-file-edit-widget\"\x3e\x3cdiv class=\"filefield-generic-edit\"\x3e\x3cdiv class=\"form-item\" id=\"edit-field-photo-0-edit-wrapper\"\x3e\n \x3cdiv class=\"filefield-icon field-icon-image-jpeg\"\x3e\x3cimg class=\"field-icon-image-jpeg\" src=\"http://amusa.oof.org/sites/all/modules/cck/filefield/icons/protocons/16x16/mimetypes/image-x-generic.png\" /\x3e\x3c/div\x3e\x3cdiv class=\"filefield-generic-edit-description\"\x3e\x3cdiv class=\"form-item\" id=\"edit-field-photo-0-edit-description-wrapper\"\x3e\n \x3cinput type=\"text\" maxlength=\"256\" name=\"field_photo[0][edit][description]\" id=\"edit-field-photo-0-edit-description\" size=\"60\" value=\"400sign.jpg\" class=\"form-text required\" /\x3e\n \x3cdiv class=\"description\"\x3eSize: 29.81 KB. Filename: \x3ca href=\"http://amusa.oof.org/files/m_img/400sign_0.jpg\"\x3e400sign.jpg\x3c/a\x3e\x3c/div\x3e\n\x3c/div\x3e\n\x3c/div\x3e\n\x3c/div\x3e\n\x3c/div\x3e\x3c/div\x3e\x3c/div\x3e\x3c/div\x3e\x3c/div\x3e\x3cscript type=\"text/javascript\"\x3ejQuery.extend(Drupal.settings, { \"basePath\": \"/\", \"ahah\": { \"edit-attach\": { \"url\": \"/upload/js\", \"event\": \"mousedown\", \"keypress\": true, \"wrapper\": \"attach-wrapper\", \"selector\": \"#edit-attach\", \"effect\": \"none\", \"method\": \"replace\", \"progress\": { \"type\": \"bar\", \"message\": \"Please wait...\" }, \"button\": { \"attach\": \"Attach\" } }, \"edit-field-photo-0-flags-field-photo-0-delete\": { \"url\": \"/filefield/js/delete/field_photo/model/0\", \"event\": \"mousedown\", \"keypress\": true, \"wrapper\": \"filefield-field-photo-0-form\", \"selector\": \"#edit-field-photo-0-flags-field-photo-0-delete\", \"effect\": \"fade\", \"method\": \"replace\", \"progress\": { \"type\": \"throbber\" }, \"button\": { \"field_photo_0_delete\": \"Delete\" } }, \"edit-field-photo-1-field-photo-1-upload\": { \"url\": \"/filefield/js/upload/field_photo/model/1\", \"event\": \"mousedown\", \"keypress\": true, \"wrapper\": \"filefield-field-photo-1-form\", \"selector\": \"#edit-field-photo-1-field-photo-1-upload\", \"effect\": \"fade\", \"method\": \"replace\", \"progress\": { \"type\": \"throbber\" }, \"button\": { \"field_photo_1_upload\": \"upload\" } }, \"edit-field-photo-2-field-photo-2-upload\": { \"url\": \"/filefield/js/upload/field_photo/model/2\", \"event\": \"mousedown\", \"keypress\": true, \"wrapper\": \"filefield-field-photo-2-form\", \"selector\": \"#edit-field-photo-2-field-photo-2-upload\", \"effect\": \"fade\", \"method\": \"replace\", \"progress\": { \"type\": \"throbber\" }, \"button\": { \"field_photo_2_upload\": \"upload\" } }, \"edit-field-photo-3-field-photo-3-upload\": { \"url\": \"/filefield/js/upload/field_photo/model/3\", \"event\": \"mousedown\", \"keypress\": true, \"wrapper\": \"filefield-field-photo-3-form\", \"selector\": \"#edit-field-photo-3-field-photo-3-upload\", \"effect\": \"fade\", \"method\": \"replace\", \"progress\": { \"type\": \"throbber\" }, \"button\": { \"field_photo_3_upload\": \"upload\" } }, \"edit-field-additional-photos-0-field-additional-photos-0-upload\": { \"url\": \"/filefield/js/upload/field_additional_photos/model/0\", \"event\": \"mousedown\", \"keypress\": true, \"wrapper\": \"filefield-field-additional-photos-0-form\", \"selector\": \"#edit-field-additional-photos-0-field-additional-photos-0-upload\", \"effect\": \"fade\", \"method\": \"replace\", \"progress\": { \"type\": \"throbber\" }, \"button\": { \"field_additional_photos_0_upload\": \"upload\" } }, \"edit-field-additional-photos-1-field-additional-photos-1-upload\": { \"url\": \"/filefield/js/upload/field_additional_photos/model/1\", \"event\": \"mousedown\", \"keypress\": true, \"wrapper\": \"filefield-field-additional-photos-1-form\", \"selector\": \"#edit-field-additional-photos-1-field-additional-photos-1-upload\", \"effect\": \"fade\", \"method\": \"replace\", \"progress\": { \"type\": \"throbber\" }, \"button\": { \"field_additional_photos_1_upload\": \"upload\" } }, \"edit-field-additional-photos-2-field-additional-photos-2-upload\": { \"url\": \"/filefield/js/upload/field_additional_photos/model/2\", \"event\": \"mousedown\", \"keypress\": true, \"wrapper\": \"filefield-field-additional-photos-2-form\", \"selector\": \"#edit-field-additional-photos-2-field-additional-photos-2-upload\", \"effect\": \"fade\", \"method\": \"replace\", \"progress\": { \"type\": \"throbber\" }, \"button\": { \"field_additional_photos_2_upload\": \"upload\" } } } });\x3c/script\x3e" }

I thought these probs might be devel module related, but I've since disabled it and this is still happening.

basically, filefield is just behaving totally erratically. I think it may be Drupal _SESSION for anonymous users that's part of the problem, because when I first hit the form, uploading a file doesn't work at all - I hit 'upload' and the form behaves as if I've hit 'submit' at the very bottom. Then on the second visit I can upload a file (though if I try to delete it, I get the HTML 0 error), and I was reading that Drupal doesn't create a session for anonymous users until the second visit - true?

Anyway, any help would be great, I'm pretty frustrated :/

elly’s picture

New information: Turning off javascript doesn't help. It seems like the form is getting submitted, but then I get "invalid for each" error in line 751 of form.inc, and the node doesn't get saved to the database.

elly’s picture

Project: FileField Image » FileField
Version: 6.x-1.0 » 6.x-3.x-dev

Moving this to filefield since it's not specifically filefield_image related

drewish’s picture

if you're using filefield_image then you're in a bad spot right now. it's not compatible with the current version of filefield so i've unpublished it. once filefield and image field are stableized i'll work on an upgrade path from filefield_image to imagefield.

elly’s picture

i've given up on filefield_image entirely, I'm now just trying to use plain ol' filefield and it's giving me those HTML 0 errors!

dopry’s picture

Status: Active » Postponed (maintainer needs more info)

I don't know what an HTML 0 error is... I've never seen one? Do you have devel.module enabled? which version of filefield are you using? if you were using filefield_image I doubt you are using 3.x...

elly’s picture

Version: 6.x-3.x-dev » 6.x-1.0-beta3
StatusFileSize
new29.79 KB

You're right, I put the wrong version in this issue report,

I'm running
filefield_image-6.x-1.0(2)
filefield-6.x-1.0-beta3

I attached a screenshot of the error box I get upon trying to delete an image I've uploaded. I'm only getting that specific error in firefox3, but many other odd things happen in other browsers

I disabled devel.module after I read it could be breaking ajax uploads, and disabling it doesn't change anything.

filefield seems to be working alright for images without the image widget, though, so I guess I'll just use it plain since dev has stopped on filefield_image!

dopry’s picture

Status: Postponed (maintainer needs more info) » Closed (fixed)

yeah those are unsupported versions now if you enable both fileifeld and imagefield you should get an image widget for filefield.