title: when there is timeout at jQuery ajax, I want to run a function
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/3543683/jquery-ajax-timeout-setting">jquery $.ajax timeout setting</a>  </p>
  </blockquote>
  
  
  
  <p>The timeout works, but when the timeout occurs, I want to execute a function. do you have any ideas how to do this?</p>
  
  <pre><code>$.ajax({
      type: "GET", 
      url: "xajax.php", 
      timeout: 100, 
      data: "name=John&amp;location=Boston", 
      success: function(msg) {
          alert( "Data Saved: " + msg );
      }
  });
  </code></pre>