title: Correct usage of $.ajaxComplete and $.ajaxError?
body: <p>I've been using the following snippet on my ajax form submits:</p>
  
  <pre><code>$.ajax({
  url: "",
  data: ilmoittautumisdata,
  type: "POST",
  success:function(){
  
  });
  error:function(){
  
  });
  });
  </code></pre>
  
  <p>However, I remember that I was told to stop using success and error within it, as they're deprecated (?) and instead use  <code>$.ajaxComplete();</code> and  <code>$.ajaxError();</code>.</p>
  
  <p>However, reading the docs isn't helping me as I want to use both of them, and this isn't working for me.</p>
  
  <pre><code>$('#ilmoittuminen').submit(function(){
              var ilmoittautumisdata = $('#ilmoittuminen').serialize();
              $.ajax({
                  //url: "",
                  data: ilmoittautumisdata,
                  type: "POST"
                  });
              $.ajaxComplete(
              function(){
              $('#ilmoittuminen').slideUp();
              });
              $.ajaxError(
              function(){
  
              });
      return false;
      });​
  </code></pre>
  
  <p>How I should do it?</p>
  
  <p><a href="http://jsfiddle.net/D7qgd/" rel="nofollow">http://jsfiddle.net/D7qgd/</a></p>