This week's book giveaway is in the Design forum.
We're giving away four copies of Building Microservices and have Sam Newman on-line!
See this thread for details.
The moose likes JSP and the fly likes Logout user by deleting cookie Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Building Microservices this week in the Design forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "Logout user by deleting cookie" Watch "Logout user by deleting cookie" New topic

Logout user by deleting cookie

Leonardo Pjetri

Joined: Dec 21, 2004
Posts: 29
here is how the cookie is detected

im trying to add a button, when clicked it kills the cookie, but so far no success
Gaurav Chhabras
Ranch Hand

Joined: Sep 21, 2005
Posts: 126
public void Cookie.setMaxAge(int expiry)

Specifies the maximum age of the cookie in seconds before it expires. A negative value ( -1 ) indicates the default, that the cookie should expire when the browser exits. A zero ( 0 ) value tells the browser to delete the cookie immediately.

you can do one thing that on click of button , you can write the code ..


It will delete the cookie immediately.
Have you checked out Aspose?
subject: Logout user by deleting cookie
It's not a secret anymore!