From 51f3fa2e2b5ac170ca545b9ca3ce208eb1587d3b Mon Sep 17 00:00:00 2001 From: scottjehl Date: Sun, 19 Sep 2010 19:02:21 -0400 Subject: [PATCH] default to no auto-submit events. --- js/jQuery.mobile.forms.autoform.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/js/jQuery.mobile.forms.autoform.js b/js/jQuery.mobile.forms.autoform.js index 959211be..defa304b 100644 --- a/js/jQuery.mobile.forms.autoform.js +++ b/js/jQuery.mobile.forms.autoform.js @@ -19,7 +19,7 @@ $.fn.autoform = function(options){ //extendable options var o = $.extend({ - submitEvents: 'change', + submitEvents: '', method: $this.attr('method'), action: $this.attr('action'), injectResponse: true,//should be data-attr driven @@ -41,7 +41,8 @@ $.fn.autoform = function(options){ data: $(this).serialize(), dataFilter: o.dataFilter, success: function(data,textStatus){ - $('.ui-page-active .ui-content').html( $('
').append(data).mobilize() ); + $('.ui-page-active .ui-content').replaceWith( data ); + $.mobilize($('.ui-page-active .ui-content')); $.pageLoading(true); } });