I have to send a http DELETE request to a server. The type has to be JSON, and the object looks like this:
{ "id": "value"}
My first approach was the following code, but so far it doesn't work:
$http.delete('http://blabla/server/house', {"id": "value"}).success(function(data) {
console.log(data);
//Redirect to index.html
$location.path('/');
});
What would a working solution look like?
$http.delete(url, [config]), not$http.delete(url, [data])