Forum Moderators: open
<SCRIPT LANGUAGE="JavaScript">
cookie_name = "affdataCookie";
var Entered;
var expdate = new Date();
expdate.setTime(expdate.getTime() + 26*24*60*60*1000);
{
if(document.cookie = document.cookie)
{
}
else
{
YouEntered=window.location.search
document.cookie=cookie_name+"="+Entered+"; expires=" + expdate.toGMTString();
}
}
</SCRIPT>
Also, you may have a logic error... you have an "if" statement that contains an assignment operator (=) instead of a comparision (==):
if(document.cookie = document.cookie)
-------------------^