2

enter image description here Here is a list of cookies. The first and second are set by the server. The third - set by the client document.cookie = "userName = Vasya". I want to get all the cookies. When I'm trying to get with document.cookie, I get only 3rd (set by the client).

How to get cookies set by the server? P.S: All cookies are installed in one session

Dmytro
  • 304
  • 2
  • 13

1 Answers1

1

You cannot access to cookies with HTTP flag on the latest version of all major browsers for security reason. For developer porpouse you can try to disable this flag. Please take a look at this post:

How to read a secure cookie using JavaScript

baymax
  • 151
  • 3