Hi,

See javadoc hor servlet.http.Cookie: you need to setMaxAge() for the
cookie, otherwise it will have an negative expire time - that is the
default, for kept in memory only (session) cookies.

The cookies you-re talking here are created, but not saved on disk,
so as long the browser is running they are OK.

Cezar.



On Wed, 21 Jul 1999, Catharine Barnes wrote:

> I sent a message about using cookies yesterday, but I am not sure if it got
> throught because I didn't get any responses to it.
>
> I am trying to create a cookie from a servlet.
>
> If I do not explicitly set the path and domain attributes my browser
> attempts to create the cookie (it asks my permission to create it). By
> clicking on more info it tells me that the path is '/servlet/' and the
> domain is hostname. However, no cookie is created.
> If I set the domain within the servlet to 'hostname:8080' is makes no
> attempt to create the cookie.
>
> Can anyone tell me where I am going wrong, or suggest a resource on the web
> that might help me.
>
> Thanks,
> Catharine

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to