title: AJAX Call is incrementing itself by +1 each time it's called
body: <p>I have a piece of JQuery AJAX that calls a VB.NET code-behind (class) that returns string data. It grabs some latest stats on a particular server. Now the code works, but the first time I press the refresh button data is returned and the alert "Refreshed" is shown on screen.</p>
  
  <p>But if I press it again, the alert box "Refreshed" is shown twice, I click again three times! and  on and on, until the time-out kicks in.</p>
  
  <p>It seems to be coming from the AJAX call and no where else. I'm at a loss at what could be calling this, I've tried deleting the data returned after success but no joy. Any ideas on what could be causing this or where to look?</p>
  
  <pre><code>function RefreshServer(btn,div,id,ip) {
  
  $('#aRefresh'+id).html("&lt;img src=images/refreshServer.gif border=0 align=absmiddle /&gt;");
  $("#"+btn).click(function() {
  $.ajax({
    type: "POST",
    url: "Dashboard.aspx/refreshServerAJAX",
    timeout: 5000,
    data: "{'IP': '" + ip + "'}",
    contentType: "application/json; charset=utf-8",
    dataType: "json",
    success: function(msg) {
      var substr = msg.d.split('%');
      $('#serverBox_mod'+id).html(" " +substr[0]);
      $('#serverBox_map'+id).html(" " +substr[1]);
      $('#serverBox_playing'+id).html(" " +substr[2] + "/" + substr[3]);
      $('#serverBox_img'+id).html("&lt;img src=images/Maps/" + substr[4] + " height=80 width=120 border=0 style=margin-top:10px;margin-bottom:10px; /&gt;");
      $('#serverBox_title'+id).html(" " +substr[5]);
      $('#aRefresh'+id).html("Refresh");
      delete substr
      delete msg
      alert("Refreshed");  
    },
    error: function(msg) {
      $('#aRefresh'+id).html("Refresh");
      $('#serverBox_title'+id).html("Server didn't respond!, sorry about that. Please try again...");
    }
  });
  });  
  }
  </code></pre>