http://qs321.pair.com?node_id=90180


in reply to Seeking help to avoid duplicate cookies

I hate to be an unhelpful jerk, but what you're describing is unlikely at best, and most probably impossible.

Try this JS code:

<html> <head> <script language="JavaScript"> function setCookie() { document.cookies = "foo=bar"; } function getCookies() { window.alert("Cookies: " + document.cookies); } </script> </head> <body> <form> <p align="center"><input type="button" value="Set A Cookie" onClick="s +etCookie();"></p> </form> </body> </html>

No matter how many times you click setCookie there's only that one cookie there. By definition cookies have to have unique names, AFAIK.

It sounds like your code is doing something unexpected in terms of how it sets/reads cookies.

Try posting some code and we can take a look...

And on a final note, if you're setting the cookie via JavaScript and reading via Perl then the error could be quite simple:

Try it by changing "=" to "+=" in my code.

HTH