<!--
function fadeOut(id, time) {
	target = document.getElementById(id);
	alpha = 100;
	timer = (time*1000)/2000;
	var i = setInterval(
			function() {
				if (alpha <= 100)
					clearInterval(i);
				setAlpha(target, alpha);
				alpha -= 2;
			}, timer);
	target.style.visibility="hidden";
	document.getElementById('flash_div').style.visibility="visible";
}

function fadeIn(id, time) {
	target = document.getElementById(id);
	document.getElementById(id).style.visibility="visible";
	document.getElementById('flash_div').style.visibility="hidden";
	alpha = 0;
	timer = (time*1000)/2000;
	var i = setInterval(
			function() {
				if (alpha >= 100)
					clearInterval(i);
				setAlpha(target, alpha);
				alpha += 25;
			}, timer);
}
function setAlpha(target, alpha) {
	target.style.filter = "alpha(opacity="+ alpha +")";
	target.style.opacity = alpha/100;
}
//-->