var ie5 = (document.getElementById && document.all); 
var ns6 = (document.getElementById && !document.all);

var timerID = null;
var opacity = 0;

function chooseAction() {
	if (opacity==100) mozDisappear(); 
	else if (opacity==0) {
	document.getElementById("cont").style.visibility = "visible";
	mozAppear();
	}
}

function mozAppear() {
		
		opacity += 10;
		if (opacity == 110) {
		opacity = 100;
		clearTimeout(timerID);
		timerID=null;
		return;
		}
		timerID = setTimeout("mozAppear()", 30);
		if(ns6) {
		document.getElementById("cont").style.MozOpacity = opacity + '%';
		}
		else if (ie5) {
		document.getElementById("cont").style.filter='alpha(opacity:' + opacity + ')';
		}
}

function mozDisappear() {
	
		opacity -= 10;
		if (opacity < 0) {
		opacity = 0;
		document.getElementById("cont").style.visibility = "hidden";
		clearTimeout(timerID);
		timerID=null;
		return;
		}
		timerID = setTimeout("mozDisappear()", 30);
		if(ns6) {
		document.getElementById("cont").style.MozOpacity = opacity + '%';
		}
		else if (ie5) {
		document.getElementById("cont").style.filter='alpha(opacity:' + opacity + ')';
		}
}