jquery Programming Glossary: ajaxdefer
jQuery: Submit a form only if no AJAX is currently running on the page http://stackoverflow.com/questions/13166176/jquery-submit-a-form-only-if-no-ajax-is-currently-running-on-the-page calls we don't do anything right away. We can use a Deferred object to help us with this. document .ready function var ajaxDefer .Deferred .resolve document .ajaxStart function ajaxDefer .Deferred .ajaxStop function ajaxDefer.resolve 'form#find users'.. object to help us with this. document .ready function var ajaxDefer .Deferred .resolve document .ajaxStart function ajaxDefer .Deferred .ajaxStop function ajaxDefer.resolve 'form#find users' .on 'submit' function ajaxDefer.always function Code.. .ready function var ajaxDefer .Deferred .resolve document .ajaxStart function ajaxDefer .Deferred .ajaxStop function ajaxDefer.resolve 'form#find users' .on 'submit' function ajaxDefer.always function Code here will always be executed as soon as..
|