This is related to:

#339196: Image uploading through popups

I've made a patch to make FileField and ImageField uploads work in a popup. I posted the Popups API part of my patch to that thread. I'm posting here the 'add and reference' node form part of the patch.

This is a simple patch that adds a hidden form field to node forms, when they're output in a popup. This form field's value is now checked by popups, instead of using any custom HTTP headers (which don't work when file uploads are involved).

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Jaza’s picture

Form field properties needed '#' at the start... no idea why it worked before, but it doesn't work for me now.

Updated patch attached.

greg.harvey’s picture

This looks really promising. Subscribing, will try to find time to test. (In combination with your other patch, naturally.)

thekayra’s picture

subscribing

Jaza’s picture

Updated patch, for this thread and for:

#339196: Image uploading through popups

See the other thread for details.

phpepe’s picture

FileSize
6.26 KB

Jaza,

I still have errors when uploading the image.
A page is loaded with a textarea containing some JSON code.
A screenshoot is attached.

Regards

kepford’s picture

subscribing

Breakerandi’s picture

subscribing

Peter Törnstrand’s picture

subscribing

vectorfrog’s picture

I have applied the patch, but I'm still getting a "Bad Response form submission" error when I try to upload an image within the popup. Any ideas why this is?

ducdebreme’s picture

subscribing

pvanerk’s picture

Hi,

I am still experiencing the "Bad Response form submission" with the module and the Popups API. I use
popups_reference 6.x-2.0-alpha1
popups 6.x-2.0-beta0

I tried the several patches but no luck on this.

Did anyone manage to get this working with the versions above?