Angular无法将函数的计算数据作为JSON发送

In a form, I am trying to send data as json to a php file, which is calculated correctly from a function in controller. But, if I try to send this calculated data as json, header shows as blank object. Can someone tell me why?

FORM:

<form id="form1" post="">
    <p ng-model="result">{{add()}}</p>
    <button type="submit" class="btn btn-default" ng-click="submitting()" >Submit</button>          
</form>

CONTROLLER:

$scope.submitting = function(){
    var request = $http({ method: "post", url: "php/store.php", 
    data: {"Answer": $scope.result} });
    request.success(function (data) { 
        //alert("Successfully data entered! "); 
    });
}


$scope.add = function(){ 
    var a = 10; var b = 20; var c = a + b;
    return c;
}

problem was inside your controller it should be like this

FORM:

<form id="form1" post="">
    <p >{{add()}}</p>
    <button type="submit" class="btn btn-default" ng-click="submitting()" >Submit</button>          
</form>

CONTROLLER:

$scope.submitting = function(){
    var request = $http({ method: "post", url: "php/store.php", 
    data: {"Answer": $scope.add()} });
    request.success(function (data) { 
        //alert("Successfully data entered! "); 
    });
}


$scope.add = function(){ 
    var a = 10; var b = 20; var c = a + b;
    return c;
}

Fiddle:https://jsfiddle.net/xrx5Lxwk/1/