title: Contact Form 7 Event Triggers - Invalid not working
body: <p>I am trying to use event triggers for contact form 7 and the submit works fine however the invalid isn't working or any of the others. I had it working for a few minutes and then it quit working - I don't know why.</p>
  <p>Any ideas no how to get these events firing?</p>
  <p><strong>Note:</strong> I noticed that this is posting to the same page (or appears to be) at the same URL with a #wpcf7-f49-p43-o1 appended. I wonder if it isn't working because it is posting and a new page is being loaded that I never see my message but the code is actually executing? From my understanding alerts pause the code till the user acknowledges them though? Thoughts on that?</p>
  <p>Here is my code:</p>
  <pre><code>$(document).ready(function() {
    /* ===========================================
     Contact Form 7
     Database Logic will make ajax posts to php script
     Post to URL's
     CUSTOM EVENT TRIGGERS:
     invalid.wpcf7, spam.wpcf7, mailsent.wpcf7, mailfailed.wpcf7, submit.wpcf7
     =========================================== */
  
    console.log('4');
  
    $(document).on('submit.wpcf7', function() {
      alert('submit.wpcf7 was triggered!');
    });
  
    $(document).on('spam.wpcf7', function() {
      alert('submit.wpcf7 was triggered!'); // Works
    });
  
    $(document).on('invalid.wpcf7', function() {
      alert('invalid.wpcf7 was triggered!');
    });
  
    $(document).on('mailsent.wpcf7', function() {
      alert('mailsent.wpcf7 was triggered!');
    });
  
    $(document).on('mailfailed.wpcf7', function() {
      alert('mailfailed.wpcf7 was triggered!');
    });
  });
  </code></pre>