Wrox Home  
Search P2P Archive for: Go

  Return to Index  

asp_databases thread: cookie expiration


Message #1 by stephen.eighmey@s... on Thu, 25 Jul 2002 14:19:40
hello,

   i have an asp page that sets a cookie value and it's expiration. the 
code i use to set the expiration is...

Response.Cookies("values").expires=dateAdd("y",1,date)

i believe this will set the cookie expiration date to 1 year from when a 
user first visits the page. i also have 2 other pages that set and 
retrieve key values for this same cookie, but, both of these other 2 asp 
pages have this same "cookie expires" line at the top of the page. my 
question is, by having this same line at the top of my other 2 asp pages 
am i cancelling out the expiration date of this cookie? do i just need to 
set it on the first asp page that is called and not on the others? i have 
noticed that the cookie seems to persist for a least a few days but 
sometimes i visit the site and it seems that my previously set cookie has 
been wiped from my system...

  Return to Index