title: Angularjs $http POST request empty array
body: <p>The following <code>$http request</code> executes successfully, yet the PHP script on the other end receives an empty <code>$_POST</code> array when it should receive 'test' and 'testval.' Any ideas?</p>
  
  <pre><code>$http({
      url: 'backend.php',
      method: "POST",
      data: {'test': 'testval'},
      headers: {'Content-Type': 'application/x-www-form-urlencoded'}
      }).success(function (data, status, headers, config) {
      console.log(data);
  
      }).error(function (data, status, headers, config) {});
  </code></pre>