I'm just getting back into the game after over 8 months of dormant slacking and I need some help. I'm trying to make a preference page on a site using cookies. When the user sets his preferences for the first time, I want the site to totally interact with them. How do i make cookies and read them?
Not too difficult, although maybe to explain in one thread. Maybe this link will help: cookies help
I'm better at learning code line by line and that site just tell you to copy what they have and change it. It doesn't really tell me too much of how it all actually works together. Could you help me with that?
copy the bakecookie and eatcookie functions. When you want to store a cookie, you use:
the name is just like a variable name, given to the data you are make a cookie of. that will overwrite any previous with the same name (aka editing preferences)
to read the cookie, use
variable = EatCookie('name')
name is the name of the value you want to retrieve, and variable is where to retrieve the restored value.
Hope that this helps you (note that the two functions musts be copied, it might be three functions)
if you want the site to really interact with the user, you should switch to a server side language such as asp or php....then you can interact through many ways
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)