jquery-helpers-for-rails3 icon indicating copy to clipboard operation
jquery-helpers-for-rails3 copied to clipboard

Remote forms won't execute JavaScript because of incorrect default dataFilter option

Open tadman opened this issue 15 years ago • 0 comments

There appears to be a problem with making AJAX form requests using the unobtrusive helper on forms with :remote => true set.

The line causing the problem is:

dataFilter:     function(data, type){ $element.trigger("dataFilterAjax", [data, type]); },

Since there is no default trigger, nothing is returned, and as such, no script is executed. Removing this line solves the problem but probably reduces functionality. If a default handler that implemented the correct pass-through behaviour was defined, this wouldn't be an issue.

tadman avatar Feb 15 '10 04:02 tadman