Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Cookie set with ASP not persisting when browser closed

Status
Not open for further replies.

mes2002

Programmer
Nov 13, 2002
2
AU
I was hoping someone could shed some light on why my cookie that I set does not persist when the browser is closed.

The current code is:
Response.Cookies("SURVEY")("N_count") = "1"
Response.Cookies("SURVEY").Expires = DateAdd("d", Date, 30)

I have also tried:
Response.Cookies("SURVEY").Expires = Date + 30
and
Response.Cookies("SURVEY").Expires = "January 10, 2003"

Nothing seems to keep the cookie on the users machine.

Any advice would be much appreciated.
 
Infact
If anyone can recommend a better way of doing the cookie setting in order for it to persist when the browser is closed, that would be appreciated.

thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top