title: AngularJS http sending post request fails
body: <p>Having this GET request, it works (sends request to the sever and server is able to handle it):</p>
  
  <pre><code>    /* post to server*/
      $http.get("/forms/FormValidator1/validateForm/" + JSON.stringify(data)).
          success(function(data) {
              console.log("good")
          }).
          error(function(data, status, headers, config) {
              console.log("something wrong")
          })
  </code></pre>
  
  <p>When I use this POST request it doesn't.</p>
  
  <pre><code> $http.post("/forms/FormValidator1/validateForm/" + JSON.stringify(data)).
                  success(function(data) {
                      console.log("good")
                  }).
                  error(function(data, status, headers, config) {
                      console.log("something wrong")
                  })
  </code></pre>
  
  <p>or writing in different form:</p>
  
  <pre><code>           $http({
                  url: '/forms/FormValidator1/validateForm',
                  method: "POST",
                  data: JSON.stringify(data),
                  headers: {'Content-Type': 'application/json'}
              }).success(function (data, status, headers, config) {
                      console.log("good")
              }).error(function (data, status, headers, config) {
                      console.log("something wrong")
              });
  </code></pre>
  
  <p>What I have in the end is: </p>
  
  <pre><code>Request URL:http://localhost:9000/forms/FormValidator1/validateForm
  Request Method:POST
  Status Code:404 Not Found
  </code></pre>
  
  <p>Requested payload is json: <code>{"name":"name1","surname":"surname1"}</code></p>
  
  <p>On the server (playframework) I defined routes that are supposed to accept client calls.</p>
  
  <pre><code>GET        /forms/FormValidator1/validateForm/:jsonForm           controllers.FormValidator1.validateForm(jsonForm:String)
  
  POST        /forms/FormValidator1/validateForm/:jsonForm            controllers.FormValidator1.validateForm(jsonForm:String)
  </code></pre>
  
  <p>Or with no <code>":jsonForm"</code></p>
  
  <pre><code> POST        /forms/FormValidator1/validateForm            controllers.FormValidator1.validateForm(jsonForm:String)
  </code></pre>
  
  <p>What might be the reason. What I missed?</p>
  
  <p><strong>UPDATE</strong></p>
  
  <p>Interestly enough: after I got it working on my laptop (see my answer below) then push it on gitHub and pull it to another machine it starts working differently. Now it complains than <strong>Bad Request</strong> is [Invalid XML] nevertheless I use <code>"application/json"</code> header and did not change any line of code after commit. I wonder maybe it is a <strong>bug</strong>.</p>
  
  <p>It seems along <code>DocumentType</code>, I need provide <code>dataType : 'json'</code>, but since Play wants it be in the url. This all does not work.</p>