title: jquery post on keyup "Fail[s] to load resource"
body: <p>I have this code:</p>
  
  <pre><code>$(document).ready(function() {
    $("#team-search").keyup(function() {
      if($("#team-search").val().length &gt; 0) {
        $("#search-results").slideDown(300);
      }
      else {
        $("#search-results").slideUp(300);
      }
      $.post("team-search.php",{team: $("#team-search").val()},function(result) {
        $("#search-results").html(result);
      });
    });
  });
  </code></pre>
  
  <p>and everything works; it sends the post request with the <code>team:$("#team-search")</code> value and it prints the results into <code>$("#search-results")</code>.</p>
  
  <p>but after typing about 20 characters, it stops printing the result and I check the error log and it says this: <code>[Error] Failed to load resource: The network connection was lost. (team-search.php, line 0)</code> every time you type a key.</p>
  
  <p>What am I doing wrong? Or what should I fix? Why is this happening?</p>
  
  <p>my network connection is really and everything else works fine</p>