summaryrefslogtreecommitdiff
path: root/misc/ajax.js
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2010-03-26 18:58:12 +0000
committerDries Buytaert <dries@buytaert.net>2010-03-26 18:58:12 +0000
commitc327b4d407c0fc3ea74037789214b23d2b35e9a0 (patch)
treeb03f23a11760e8f511bf9d5b0d3781f5a16a4458 /misc/ajax.js
parenta7d001f7d18c738875fc846dbb719c4bbdf9272b (diff)
downloadbrdo-c327b4d407c0fc3ea74037789214b23d2b35e9a0.tar.gz
brdo-c327b4d407c0fc3ea74037789214b23d2b35e9a0.tar.bz2
- Patch #684846 by effulgentsia, rfay, quicksketch, aspilicious: AJAX triggered by non-submit element fails if any elements are validated.
Diffstat (limited to 'misc/ajax.js')
-rw-r--r--misc/ajax.js8
1 files changed, 2 insertions, 6 deletions
diff --git a/misc/ajax.js b/misc/ajax.js
index 3d0357cbc..23179fd07 100644
--- a/misc/ajax.js
+++ b/misc/ajax.js
@@ -98,7 +98,7 @@ Drupal.ajax = function (base, element, element_settings) {
type: 'bar',
message: 'Please wait...'
},
- button: {}
+ submit: {}
};
$.extend(this, defaults, element_settings);
@@ -121,7 +121,7 @@ Drupal.ajax = function (base, element, element_settings) {
var ajax = this;
var options = {
url: ajax.url,
- data: ajax.button,
+ data: ajax.submit,
beforeSerialize: function (element_settings, options) {
return ajax.beforeSerialize(element_settings, options);
},
@@ -200,10 +200,6 @@ Drupal.ajax.prototype.beforeSubmit = function (form_values, element, options) {
// Disable the element that received the change.
$(this.element).addClass('progress-disabled').attr('disabled', true);
- // Server-side code needs to know what element triggered the call, so it can
- // find the #ajax binding.
- form_values.push({ name: 'ajax_triggering_element', value: this.formPath });
-
// Insert progressbar or throbber.
if (this.progress.type == 'bar') {
var progressBar = new Drupal.progressBar('ajax-progress-' + this.element.id, eval(this.progress.update_callback), this.progress.method, eval(this.progress.error_callback));