Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

259
Views
Can't Access or Delete Cookie sent from Express in Client

My Express server is sending a cookie to the client that is not httpOnly. Even so, the client doesn't have access to the cookie on document.cookie nor is the cookie showing up in the Application tab on chrome dev tools. However, I can see the cookie in Chrome settings Cookie and Site-data page. My original problem was trying to delete the cookie on the client side in the case the client becomes offline but I can't do that if I can't access the cookie in the first place.

On the server: res.cookie("mycookie", "test", {httpOnly: false}); On the client document.cookie is undefined

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Turns out the issue was with NGINX. www.mydomain.com and mydomain.com were both serving the same webpage. Cookies are tied to their domain and technically www.mydomain.com is different from mydomain.com. Added server blocks to my website config in NGINX to forward all traffic to www.mydomain.com to mydomain.com.

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!