Help me on this:
I am sending JSON data through angularjs to laravel :
My angularjs Json code like:
$scope.addnew = {name:'',email:'',message:''};
$scope.addnew.name=$scope.name;
$scope.addnew.email=$scope.email;
$scope.addnew.message=$scope.message;
$http.post("url",$scope.addnew)
.then(function mysuccess(response) {
console.log(response.data);
});
Note: I have predefined url in my file.
And I want to receive this JSON file in my laravel controller so that all data can be saved in my mysql table "contactemail" and fields of table are named as name for name, email for email and message for message of user. As I am newbie in Laravel I am not able to do this correctly.Please Help me in this.