Can javascript read a cookie from a different domain?\
If i set a cookie in one domain say www.domain1.com. Can i read that cookie from a different domain www.domain2.com?
If yes, how?
No, the document.cookie
property only gives you access to the cookies relevant to that page. Being able to read other cookies would be a fairly significant security issue.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With