
if(document.cookie == "")
{
	document.cookie = "mute=0";
}
	
var openWindow = 0;
function roll(imgName) {
document[imgName].src = "i/" + imgName + "-on.gif"
}

function out(imgName) {
	document[imgName].src = "i/" + imgName + ".gif"	
}
function openIT(page)
{
	if(openWindow){openWindow.close();}
	openWindow = window.open(page,"n","width=485,height=455,status=0,scrollbars=0,resizable=0") 
}

function popSWF(movie)
{
	if(openWindow){openWindow.close();}
	openWindow = window.open(movie,"n","width=450,height=400,status=0,scrollbars=0,toolbars=0") 
}

var popUpWin=0;
function popUpWindow(URLStr, left, top, width, height)
{
  if(popUpWin)
  {
    if(!popUpWin.closed) popUpWin.close();
  }
  popUpWin = open(URLStr, 'popUpWin', 'toolbar=no,location=no,directories=no,status=no,menub ar=no,scrollbars=yes,resizable=no,copyhistory=yes,width='+width+',height='+height+',left='+left+', top='+top+',screenX='+left+',screenY='+top+'');
}



//called by the Flash movie when the sound is toggled
//cookie should be read each time a page is loaded
function setMuteCookie(bool)
{
	document.cookie = (bool)? "mute=1"+document.cookie:"mute=0"+document.cookie;
}

function getMuteValue()
{
	return document.cookie.substring(5,6);
}

function setWinnerCookie()
{
	document.cookie = document.cookie+"contestClicked=1";
}

function getWinnerCookie()
{
	if(document.cookie.indexOf("contestClicked=1") != -1)
	{
		
		return true;
	}
	else
	{
		return false;
	}
}
