javascript - How to read cookie from the response header? -


hi developing web application in angularjs. on successful login returning cookies. trying read cookies in success function ends undefined.

response image

   $http.post(url, sub).then(function (response) {                  //trying read cookieheaders=logintoken=63d4551a-2c09-4b08-9b4b-837f0f3806fd&loginid=2                     settimeout(function () { loginsuccess(response); }, 1000);                 }, function (error) {                     settimeout(function () { hideloader(); }, 1000);                     toastr.error($filter('translate')(error.data.msg));                 }); 

i tried inside success function console.log($cookiestore.get('cookieheaders'));

it gives me undefined.

may know possible read above cookie inside success function? in regard appreciated. thank you.


Comments

Popular posts from this blog

node.js - Node js - Trying to send POST request, but it is not loading javascript content -

javascript - Replicate keyboard event with html button -

javascript - Web audio api 5.1 surround example not working in firefox -