In the ctools auto submit javascript, the events 'keyup' and 'change' have had added to them a timeout to avoid 'bounce', which would cause undesirable effects.

In setTimeout() a jQuery proxy is used to store the context (in this case 'this.form') for the function triggerSubmit(). If the 'change' or 'keyup' event is triggered and immediately afterwards the DOM form element is removed, the function triggerSubmit() is called with a copy of the now-removed form, which is submitted to the server.

To avoid this you need to add a check of the context(this) presence in the DOM.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

artemln’s picture

Status: Active » Needs review
FileSize
643 bytes

vasi’s picture

Status: Needs review » Reviewed & tested by the community

I encountered the same problem, and came to the same conclusion. Patch works for me.

rivimey’s picture

Issue summary: View changes

Try to clarify issue summary, partly successful.

rivimey’s picture

rivimey’s picture

Issue summary: View changes
rivimey’s picture

Issue tags: +Dublin2016

Sorry for multiple summary edits.

The patch is good and applies cleanly to 7.x-1.x.

This code looks good, and looks harmless to me, so despite having only one other 'vote' it would seem sensible to include it.

rivimey’s picture

japerry’s picture

Status: Reviewed & tested by the community » Fixed

Got it, that makes sense. Committed.

  • japerry committed d133db0 on 7.x-1.x authored by artemln
    Issue #2275355 by artemln: Auto submit to submit a non-existent form
    
MustangGB’s picture

Wouldn't mind if the JS people could give a bit of love to the other autosubmit issue over at #1708438: Incompatibility Between Chaos Tools Auto Submit and Autocomplete Fields!.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.