I need to post a user id and collect the necessary information from the server (the server part already works) and return a JSON. Most of the problems I have had with the cors but despite having searched, I have not found the solution.
var link : String = "DIRECCION/PHP";
this.http.post(link.toString(), "HOLA=HOLA").subscribe(
data => {
console.log(data);
return data;
},
error=> {
console.error(error);
},
() =>
{
});