title: Ajax returns status code 200, success function not triggering
body: <p>There are quite a few topics about this, but none of them were any help.
  Everything is working fine, the data gets inserted into the db, and (i'm using spring mvc as back-end) my controller handles everything correctly as well.</p>
  
  <p>Ajax-code;</p>
  
  <pre><code>$.ajax({
                  type: "POST",
                  url: "http://localhost:8080/NotePath/register",
                  data: "email=" + email + "&amp;password=" + password + "&amp;name=" + name,
                  succes: function(response){
                      $("#formMail, #formPass, #formUsername").val("");
                      $("#loginRegister, #whiteBg").fadeOut();
                  },
                  error: function(xhr,err){
                      alert("readyState: "+xhr.readyState+"\nstatus: "+xhr.status);
                      alert("responseText: "+xhr.responseText);
                  }
  });
  </code></pre>
  
  <p>Controller code;</p>
  
  <pre><code>@RequestMapping(value = "/register")
  public @ResponseBody String registerUser(@RequestParam(value = "email") String    email, @RequestParam(value ="password") String password, 
          @RequestParam(value = "name") String name, Model model){
  
      String status = "";
  
      Boolean isEmailTaken = registerServiceImpl.isEmailTaken(email);
      Boolean isNameTaken = registerServiceImpl.isNameTaken(name);
  
      if(isEmailTaken == false &amp;&amp; isNameTaken == false){
          try {
              registerServiceImpl.registerUser(email, password, name);
              status = "Succes";
          } catch (Exception e) {
              status = "Error";
              e.printStackTrace();
          }
      }else if(isEmailTaken == true){
  
          status = "mail taken";
  
      }else if(isNameTaken == true){
  
          status = "name taken";
  
      }
  
      return status;
  
  }
  </code></pre>
  
  <p>I even tried returning a responseEntity;</p>
  
  <pre><code>return new ResponseEntity&lt;String&gt;(status, respHeader, HttpStatus.OK);
  </code></pre>
  
  <p>When I look at my response header (using google chrome) it even says "mail taken" or "name taken" or whatever message that should appear. But for some reason the ajax success function is not getting triggered...</p>
  
  <p>Weird thing is that I have other ajax calls that do work without any problem.</p>
  
  <p>I thought getting a status code of 200 meant that everything was...well....OK :p</p>