Here is my app.js, I want to send the value of email
to the file handler.php
$scope.doForget={email:''};
$scope.doForget = function (customer) {
//email = $scope.forget.email; For Testing i am hardcoding the value
email = 'abc@xyz.com';
Data.post('handler.php', {
email: email
}).then(function (results) {
console.log(results);
});
};
In the Inspect Element -> Networks i can see the form values as {email: "abc@xyz.com"}
In the handler.php
i use to print the values by print_r($_POST);
and even print_r($_GET);
but i am always getting the empty array i.e.,
Array
(
)
How can i get the values ?
Update :
I even tried this one
$scope.doForget={email:''};
$scope.doForget = function (email) {
email = 'abc@xyz.com';
Data.post('eloquent.php', {
email: email
}).then(function (results) {
console.log(results);
});
};