This week's book giveaway is in the JavaFX forum.
We're giving away four copies of Introducing JavaFX 8 Programming and have Herbert Schildt on-line!
See this thread for details.
The moose likes Tomcat and the fly likes cookie value set problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Introducing JavaFX 8 Programming this week in the JavaFX forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "cookie value set problem" Watch "cookie value set problem" New topic

cookie value set problem

ethem narman

Joined: Oct 16, 2008
Posts: 12

In a filter I am accessing cookies and trying to set the value of JSESSIONID cookie with

//some loop code

// response.addCookie(cookie);

My problem is if I use it as above new value is NOT set, when I uncomment addCookie function, I get an additional cookie called JSESSIONID again. I do not want to have an additional one but just update the old one.
I've read Tough Cookie thread but I could not see any solution.
So how do I JUST update a cookie without getting an additional one?

I agree. Here's the link:
subject: cookie value set problem
It's not a secret anymore!