$browser=(function() {
	var browser=navigator.userAgent;
	return { 
		'ie':/MSIE/i.test(browser),
		'ff':/Firefox/.test(browser),
		'moz':/Mozilla/.test(browser),
		'ns':/Netscape/.test(browser),
		'op':Boolean(window.opera),
		'saf':/WebKit/i.test(browser),
		'kq':/Khtml/i.test(browser)
	}
})();

function inizializza() {
	if (window.highlighting)
		clearInterval(highlighting);
	if (window.lowlighting)
		clearInterval(lowlighting);
}
function fade_on(which2) {
	inizializza();
		
	theobject=document.getElementById(which2);
	
	theobject.style.display='inline';
	if ($browser.ie)
		theobject.style.filter="alpha(opacity=0)";
	else 
		theobject.style.MozOpacity=0;
		
	highlighting=setInterval("highlightit(theobject)",150);
}
function highlightit(cur2) {
	if (cur2.style.MozOpacity<1)
		cur2.style.MozOpacity=parseFloat(cur2.style.MozOpacity)+0.1;
	else if (cur2.filters&&cur2.filters.alpha.opacity<100)
		cur2.filters.alpha.opacity+=10;
	else if (window.highlighting)
		clearInterval(highlighting);
}

function fade_off(which2) {
	inizializza();

	theobject=document.getElementById(which2);
	lowlighting=setInterval("lowlightit(theobject)",150);
}
function lowlightit(cur2) {
	if (cur2.style.MozOpacity>0)
		cur2.style.MozOpacity=parseFloat(cur2.style.MozOpacity)-0.1;
	else if (cur2.filters&&cur2.filters.alpha.opacity>0)
		cur2.filters.alpha.opacity-=10;
	else if (window.lowlighting)
		clearInterval(lowlighting);
}

