Hi, guys. I'm running tomcat 6.0.3 and I'm having a problem with cookies in 
jsp. After I set a cookie time using cookie.setMaxAge(3600), when I run 
cookie.getMaxAge() I get -1 instead of 3600(cookie is a object of type 
javax.servlet.http.Cookie). As I read on the internet about this issue I 
understood that depending on application server and configuration, cookies can 
be generated automatically by servlet engine. In such case you can control the 
max age trough configuration. As I understand, the reason why i get -1 is 
because

The server sets cookie values using this response header:
Set-Cookie: NAME=VALUE; expires=DATE;
path=PATH; domain=DOMAIN_NAME; secure

while client sends cookies using this request header:
Cookie: NAME1=OPAQUE_STRING1; NAME2=OPAQUE_STRING2

So to my understanding, I need to configure this somehow in tomcat. true? I 
haven't found any articles related to this though anywhere. Can someone help me 
out with some info?? 10x a lot in advance


       
____________________________________________________________________________________Ready
 for the edge of your seat? 
Check out tonight's top picks on Yahoo! TV. 
http://tv.yahoo.com/

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to