
function Toggle(item)
{
	obj = document.getElementById(item);
	visible = (obj.style.display != "none")
	if (visible)
	{
		obj.style.display="none";
	}
	else
	{
		obj.style.display="block";
	}
}


function PopUp(url, width, height) 
{
	popupWin = window.open(url,'win','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0,width=' + width + ',height='+height);
}


function DisplayAboutEclipse()
{
	var isIE = document.all?true:false;
	if (isIE)
	{
		obj = document.getElementById('abouteclipse'); 
		obj.style.visibility = "visible";
		x = (window.Event) ? e.pageX : event.clientX;
		y = (window.Event) ? e.pageY : event.clientY;
		obj.style.posLeft = x + document.body.scrollLeft;
		obj.style.posTop = y + document.body.scrollTop;
	}
}


function HideAboutEclipse() 
{
	obj = document.getElementById('abouteclipse'); 
	obj.style.visibility = "hidden";
}


var images = new Array(6);
images[0] = "http://www.uslandco.com/images/uslandcofreedom1.jpg";
images[1] = "http://www.uslandco.com/images/uslandcofreedom2.jpg";
images[2] = "http://www.uslandco.com/images/uslandcofreedom3.jpg";
images[3] = "http://www.uslandco.com/images/uslandcofreedom4.jpg";
images[4] = "http://www.uslandco.com/images/uslandcofreedom5.jpg";
images[5] = "http://www.uslandco.com/images/uslandcofreedom6.jpg";
var choice = pickRandom();

function pickRandom()
{
	var index = Math.floor(Math.random() * images.length);
	return index
}

		
function ChangeToY(starnumber) 
{
	var temp = starnumber;
	
	while (starnumber >= 1)
	{
		document[starnumber + 'star'].src = yellowstar.src;
		starnumber = starnumber - 1;
	} 
	
	starnumber = temp;
	
	while (starnumber < 5)
	{
		starnumber = starnumber + 1;
		document[starnumber + 'star'].src = blankstar.src;
	} 

}


function clickButton(e, buttonid)
{ 
	var bt = document.getElementById(buttonid); 
	if (typeof bt == 'object')
	{ 
		if(navigator.appName.indexOf("Netscape")>(-1))
		{ 
			if (e.keyCode == 13)
			{ 
				bt.click(); 
				return false; 
			} 
		} 
		if (navigator.appName.indexOf("Microsoft Internet Explorer")>(-1))
		{ 
			if (event.keyCode == 13)
			{
				bt.click(); 
				return false; 
			} 
		} 
	}
} 
