Ionic native http POST is not sending data to the server


#1

Hi, I ran into the one problem. POST is not sending data to the server. GET is working fine. Below is my code:-

post(user){

let bodynow = {

“email_id”: “aa@gmsd.sdf”,

“mobile”:“9978897989”,

“first_name”: “dfdf”,

“last_name”: “ghgfh”,

“user_title”:“MS”,

“country_code”: “91”

}

const url =

https://www.allevoyage.com/index.php/hotels_android/update_profile”;

this.http.setDataSerializer(“json”);

this.http

.post(url, bodynow,headers)

.then(data => {

console.log(data,data.url);

})

.catch(err => {

console.log(err);

});

}

cordova-plugin-advanced-http version:-2.0.1

ionic-native/http version:-4.17.0

“cordova-ios”: “4.5.5”.

I’m gettng the status as 200 with no result found error, when I call from postman, i’m getting the data. So its not issue with server side code. Anyone tell me where I went wrong.