title: angular-php: form data is empty in php
body: <p>I am using angular as frontend and php as backend here is the code of angular.</p>
  
  <pre><code>$scope.processForm = function($scope.formData) {
      console.log($scope.formData);
      $http({
          method  : 'POST',
          url     : 'process.php',
          data    : {'data': $scope.formData,'uid':uid}, // no need to use $.param, even never see it in angular
          headers : { 'Content-Type': 'application/x-www-form-urlencoded' }  
      })
  </code></pre>
  
  <p>here is the <strong>process.php</strong></p>
  
  <pre><code>$postContent= file_get_contents("php://input"); 
  $req= json_decode($postContent); 
  $formData= $req-&gt;formData; 
  $uid= $req-&gt;uid;
  </code></pre>
  
  <p>problem is $formData is empty in php. however $uid is showing value.</p>
  
  <p>in form i have two entry email and password but i don't know how can i use that in php because formdata is empty.</p>
  
  <p>I checked in firebug and found data is posting.</p>
  
  <pre><code>{"formData":{"password":"ff","cpassword":"errgreg"},"uid":"75"}:""
  </code></pre>
  
  <p>But nothing is coming response tab of firebug.</p>