title: jQuery Click Event Delay
body: <p>I have a button that triggers (1) the application of a coupon code and (2) the submission of the entire form for payment. </p>
  
  <p>The problem is that the coupon code is taking a couple of seconds to apply so is applying after the entire form is submitted for payment. How can I delay the click of the second payment button so that the coupon code button is applied first?</p>
  
  <pre><code>&lt;script type="text/javascript"&gt;
  jQuery('.js-coll-button2').click(function(e) {
    e.preventDefault();
    jQuery('#sc_checkout_form_1').find('.sc-coup-apply-btn').click();
    jQuery('#sc_checkout_form_1').find('.sc-payment-btn').click();
  });
  &lt;/script&gt;
  </code></pre>