function setCookie(cookieName, cookieValue, cookiePath,  
cookieExpires)  
{

cookieValue = escape(cookieValue);  
if (cookieExpires == "")  
{  
var nowDate = new Date();  
nowDate.setMonth(nowDate.getMonth() + 6);  
cookieExpires = nowDate.toGMTString();  
}  

if (cookiePath != "")  
{  
cookiePath = ";Path=" + cookiePath;  
}  

document.cookie = cookieName + "=" + cookieValue +  
";expires=" + cookieExpires + cookiePath;
}

function getCookie(name)  
{
var cookieString = document.cookie;  
var index = cookieString.indexOf(name + "=");  

if (index == -1)
{
return null;  
}

index = cookieString.indexOf("=", index) + 1;  
var endstr = cookieString.indexOf(";", index);  

if (endstr == -1)
{
endstr = cookieString.length;  
}

return unescape(cookieString.substring(index, endstr));
}
function doPopup()
{
 var notice = getCookie('popupShown');
 setCookie('popupShown', 'true', '', '');

 if(notice != 'true')
 { // Show the popup window
   createWindow('Important Notice', 225, '#D6E1F5', 1, 0, 400, 140);
 }
}