It appears that when using jquery 1.4.2, the filefield and imagefield cannot use the remove function.

Comments

corey.aufang’s picture

I have also run into this problem.

Downgrading to jQuery 1.3.2 fixed the problem, tho not the preferred solution.

quicksketch’s picture

I think FileField works fine with jQuery 1.4.3, you're probably getting a JavaScript error on the page which is causing all JavaScript on the page to fail.

BogdanN’s picture

I'm not getting any js errors. And it might not necessarily be a filefield's problem, but could also be connected to some Drupal's form processing js.

mcpuddin’s picture

I have a similar problem.. Here is what happens:

1. I click remove
2. The AJAX handler goes out
3. The AJAX handler returns a result
4. Nothing is updated because of an AHAH response parse error

This is not a filefield thing but rather a "AHAH is not completely compatible with jquery 1.4.2"

jgoslow’s picture

I'll second this. My imagefield_crop remove button breaks when I have jquery 1.4.2 included, and works with 1.3. Unfortunately I'm depending on 1.4.2 features.... hope this issue gets resolved soon, as it makes the file fields entirely unusable with the newest version of jquery.

quicksketch’s picture

Could someone explain exact steps to reproduce this problem (from a fresh install, including all module versions and libraries)? I have to say that even jQuery Update notes that jQuery 1.4.x is not well supported within Drupal 6. Most likely some JavaScript error is occurring that prevents all JavaScript from functioning properly.

jyg’s picture

I'm getting this error with 1.3.2. No idea where to go from here. I'd tried every version. When I use 1.3.2 I get the following after hitting the remove button:

uncaught exception: Syntax error, unrecognized expression: >

with no more details. Though the postback data looks broken. Note the trailing > at the bottom of the response... and note the error msg.

{ "status": true, "data": "\x3cdiv id=\"edit-field-preview-image-0-ahah-wrapper\"\x3e\x3cdiv class=\"form-item\" id=\"edit-field-
.....
\"field_resource_attachment_0_filefield_remove\": \"Remove\" } } });\x3c/script\x3e" }
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:foaf="http://xmlns.com/foaf/0.1/"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">

quicksketch’s picture

Another module is breaking the AJAX callbacks. In this case, i looks possibly like Purl or RDF? I'd suggest disabling modules related to that functionality. If the problem goes away, file a bug report with that module.

jyg’s picture

That's (RDF) the ticket. I was disabling other modules methodically, but the RDF stuff didn't stand out as a culprit to try first. Thanks.

jyg’s picture

I found when I shut off the RDF module, Remove worked fine

http://drupal.org/node/898284#comment-3668472

quicksketch’s picture

Category: bug » support
Priority: Major » Normal
Status: Active » Closed (fixed)

Closing this request. This is not a FileField problem but one with using newer version of jQuery which aren't supported by Drupal core or the jQuery Update module. If you're experiencing this problem, check with the jQuery Update module.