I want to send the document cookie in the http call in angular. I have already used withCredentials but it can only send the browser level cookie. I also use the cross domain ,but it is not working fine. Below is the code which I am using.
$http({
method: 'GET',
url: url,
xhrFields: { withCredentials: true },
crossDomain: true,
header:{ 'SHOPSESSIONID' : sessionStorage.getItem("SHOPSESSIONID") }
}).success(function(data){
return data;
}).error(function(data){
return data;
});