ADBlock is blocking some content on the site

ADBlock errore
Results found: 


I have a strange problem. I want to check if .ASPXAUTH cookie exists with javascript. I do it like this:

authx = document.cookie.indexOf(".ASPXAUTH" + "=");  

and the 'authx' value is always -1. But if I tray to find some other cookie like:

foo = document.cookie.indexOf("bar" + "=");  

it works. Is there some restriction between javascript and .ASPXAUTH cookie???


I solved it. The problem was, that I had set the

HttpOnly = true;  

which prevents the javascript accessing the cookie. I just set it to false and it works.

If you like, leave us your opinion

Was the article helpful and is it translated correctly?

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow