Click to See Complete Forum and Search --> : Need help understanding this?


matius
05-23-2003, 09:03 AM
I don't know what they want me to do here:

I need to create a document that stores and reads cookies containing a user's name and the number of times he/she has visited a particular Web site. The I have to display the cookies in an alert box each time the user visits the site. At that point I increment the counter cookie by one, and the reset the counter cookie expiration date to one year from the current date.

So, I just throw the user's name into a cookie with the other information? Are they asking me to get the user name? Why do I set the expiration date to one year from the current date? Confused >

Thanks for any help!

pyro
05-23-2003, 09:47 AM
Originally posted by matius
So, I just throw the user's name into a cookie with the other information?Yes.

Originally posted by matius
Are they asking me to get the user name?Aparently. Probably done via a prompt.

Originally posted by matius
Why do I set the expiration date to one year from the current date?So the cookie will expire one year after the last day they visit the site.