function setCookie(name, value, expiredays)
{
	var todayDate = new Date();
	todayDate.setDate( todayDate.getDate() + expiredays );
	document.cookie = name + "=" + escape( value ) + "; path=/; expires=" + todayDate.toGMTString() + ";"
}

function endPopWindow(ID)
{
	if (frmPop.chkToday.checked)
		setCookie(ID , "done" , 1);
	self.close();
}

function closePopWindow(mainLink)
{
	opener.location.href = mainLink;
	self.close();
}


function closePopLayer(ID)
{
	document.getElementById(ID).style.display='none';
}

function endPopLayer(ID)
{
	setCookie(ID, "none", "1");
	document.getElementById(ID).style.display='none';
}
