PDA

View Full Version : JavaScript Cookie Help


NetNessie
05-14-2005, 04:33 AM
G'day all,

I need a little hand with a JavaScript function which opens a cookie and grabs a value.

Could anyone show me how to make a small script that loads a value from a cookie. The cookie only stores one value, in the form of style=ID.

The script should return the value of ID if the cookie exists, or return null if the cookie does not exist.

Any help would be appreciated. http://forums.3drealms.com/ubbthreads/images/graemlins/grin.gif

KillerByte
05-14-2005, 10:43 AM
I recommend you read this (http://webmonkey.wired.com/webmonkey/98/29/index1a_page7.html). http://forums.3drealms.com/ubbthreads/images/graemlins/smile.gif

That website is very useful for many JavaScript queries.

NetNessie
05-15-2005, 02:51 AM
That site helped a lot, cheers. http://forums.3drealms.com/ubbthreads/images/graemlins/grin.gif