if I do this I can get a data .. but, it's not json..
var url = 'inputtest.php';
$http({
method: 'POST',
url: url,
data: $.param($scope.company),
headers: { 'Content-Type': 'application/x-www-form-urlencoded; charset=UTF-8'}
}).success(function(response){
console.log(response);
});
so, if I change like this
headers: { 'Content-Type': 'application/json; charset=UTF-8'}
I don't get any parameter from it.
===> headers info says "Request Payload" ?? instead of Request Data
server side. just testing it.
echo json_encode($_REQUEST);
I don't know what's wrong and how to fix it.
Any advice ?