title: JQuery blur and hide causing over-firing
body: <p>I'm using  jQuery v1.11.2 and have created a basic JSFiddle here (<a href="http://jsfiddle.net/k1g3upbv/" rel="nofollow">http://jsfiddle.net/k1g3upbv/</a>).  It does not show up very well in JSFiddle because my project also uses twitter Bootstrap.  I also rushed through the JSFiddle a bit because I had to remove code to simplify (e.g. removing my AJAX calls)... so please just use the JSFiddle code as a guide.</p>
  
  <p>What <strong><em>should</em></strong> happen :</p>
  
  <ul>
  <li>User enters ID to check</li>
  <li>AJAX call is made when <em>focus &amp;&amp; ID > 10</em> or <em>blur &amp;&amp; id>10</em></li>
  <li>The AJAX call ends by hiding the input field and displaying a clear button</li>
  <li>Upon clicking the clear button, the field re-appears and result and input boxes silently cleared</li>
  </ul>
  
  <p>What <strong><em>does</em></strong> happen :</p>
  
  <ul>
  <li>User enters ID to check</li>
  <li>AJAX call is made when <em>focus &amp;&amp; ID > 10</em> or <em>blur &amp;&amp; id>10</em></li>
  <li>The AJAX call ends by hiding the input field and displaying a clear button</li>
  <li>Upon clicking the clear button, the blur function is called again and a fresh result pulled by AJAX flashes up again a second time.</li>
  </ul>
  
  <p>How can I avoid a conflict between the clear button and blur function ?</p>
  
  <pre><code>&lt;div id="CheckerDiv"&gt;ID:
      &lt;input type="text" id="CheckerID" /&gt;
  &lt;/div&gt;
  &lt;div id="CheckerClearDiv" style="display:none"&gt;
      &lt;a href="" id="CheckerClearDivButton"&gt;&lt;/a&gt;
  &lt;/div&gt;
  &lt;div id="CheckerResult"&gt;&lt;/div&gt;
  
      (function (checkweb, $, undefined) {
      checkweb.Checker = function (vNumber) {
          console.log('ajax fired');
          var msgBox = $("#CheckerResult");
          var checkerDiv = $("#CheckerDiv");
          var checkerClearDiv = $("#CheckerClearDiv");
          // do stuff here that returns an ajax
          msgBox.html('AJAX RETURN !');
          checkerDiv.hide();
          checkerClearDiv.show();
          setTimeout(function () {
              msgBox.text('');
          }, 15000);
      };
  }(window.checkweb = window.checkweb || {}, jQuery));
  
  $(document).ready(function () {
      // ID checker
      $('#CheckerDiv').on("blur", '#CheckerID', function (e) {
          var n = $('#CheckerID').val();
          if (n.length &gt; 10) {
              console.log('blur fired');
              checkweb.Checker(n);
          }
          $('#CheckerID').val('');
          setTimeout(function () {
              $("#CheckerResult").text('');
          }, 5000);
      });
      $('#CheckerDiv').on("keyup change", '#CheckerID', function (e) {
          var n = $(this).val();
          if (n.length &gt; 10) {
              console.log('change fired');
              checkweb.Checker(n);
          }
      });
      $('#CheckerClearDivButton').on("click", function () {
          console.log('button fired');
          $('#CheckerID').val('');
          $("#CheckerResult").text('');
          $("#CheckerClearDiv").hide();
          $("#CheckerDiv").show();
      });
      //
  });
  </code></pre>