var showImages = true;

function enlargeFonts (size1) {
//	alert(document.styleSheets[]);
	if (navigator.userAgent.search("MSIE") != -1) {
		if ((parseInt(document.styleSheets[0].rules[0].style.fontSize) + size1 > 7) && (parseInt(document.styleSheets[0].rules[0].style.fontSize) + size1 < 20))
			document.styleSheets[0].rules[0].style.fontSize = (parseInt(document.styleSheets[0].rules[0].style.fontSize) + size1) + 'px';
		if ((parseInt(document.styleSheets[0].rules[1].style.fontSize) + size1 > 7) && (parseInt(document.styleSheets[0].rules[1].style.fontSize) + size1 < 20))
			document.styleSheets[0].rules[1].style.fontSize = (parseInt(document.styleSheets[0].rules[1].style.fontSize) + size1) + 'px';
	}
	else {
		if ((parseInt(document.styleSheets[0].cssRules[0].style.fontSize) + size1 > 7) && (parseInt(document.styleSheets[0].cssRules[0].style.fontSize) + size1 < 20))
			document.styleSheets[0].cssRules[0].style.fontSize = (parseInt(document.styleSheets[0].cssRules[0].style.fontSize) + size1) + 'px';
		if ((parseInt(document.styleSheets[0].cssRules[1].style.fontSize) + size1 > 7) && (parseInt(document.styleSheets[0].cssRules[1].style.fontSize) + size1 < 20))
			document.styleSheets[0].cssRules[1].style.fontSize = (parseInt(document.styleSheets[0].cssRules[1].style.fontSize) + size1) + 'px';
	}
}

function toggleImages () {
//	alert(document.images.length);
	for (i = 0 ; i < document.images.length ; i++) {
		if (showImages) {
			document.images[i].style.visibility = "hidden";
		//	document.images[i].style.display = "none";
		}
		else {
			document.images[i].style.visibility = "visible";
		//	document.images[i].style.display = "inline";
		}
	}
	showImages = !showImages;
}






function showToolbarMenu (td1) {
	if (navigator.userAgent.search("MSIE") != -1) {
		var arrNodes = document.getElementsByTagName("SELECT"), i;
		for (i = 0 ; i < arrNodes.length ; i++) {
			arrNodes[i].style.visibility = "hidden";
		}
	}
	td1.lastChild.firstChild.width = td1.offsetWidth + 1;
	td1.lastChild.style.visibility = "visible";
}

function hideToolbarMenu (div1) {
	if (navigator.userAgent.search("MSIE") != -1) {
		var arrNodes = document.getElementsByTagName("SELECT"), i;
		for (i = 0 ; i < arrNodes.length ; i++) {
			arrNodes[i].style.visibility = "visible";
		}
	}
	div1.style.visibility = "hidden";
}


function showMenu (td1) {
	if (navigator.userAgent.search("MSIE") != -1) {
		var arrNodes = document.getElementsByTagName("SELECT"), i;
		for (i = 0 ; i < arrNodes.length ; i++) {
			arrNodes[i].style.visibility = "hidden";
		}
	}
	td1.lastChild.style.marginTop = - (td1.firstChild.offsetHeight);
	td1.lastChild.style.marginLeft = td1.firstChild.offsetWidth;
	td1.lastChild.style.visibility = "visible";
}

function hideMenu (div1) {
	if (navigator.userAgent.search("MSIE") != -1) {
		var arrNodes = document.getElementsByTagName("SELECT"), i;
		for (i = 0 ; i < arrNodes.length ; i++) {
			arrNodes[i].style.visibility = "visible";
		}
	}
	div1.style.visibility = "hidden";
}


function startDiv (div1, dir) {
	var x = 2, delay = 4;
	var moving;

	moving = window.setInterval("scrollDiv('" + div1 + "', " + x + ", " + dir + ")", delay);
	return moving;
}

function speedDiv (div1, dir) {
	var x = 6, delay = 4;
	var moving;

	moving = window.setInterval("scrollDiv('" + div1 + "', " + x + ", " + dir + ")", delay);
	return moving;
}

function scrollDiv (div1, x, dir) {
	if (dir == 4) {
		document.getElementById(div1).scrollLeft -= x;
	}
	else if (dir == 1) {
		document.getElementById(div1).scrollTop -= x;
	}
	else if (dir == 2) {
		document.getElementById(div1).scrollLeft += x;
	}
	else if (dir == 3) {
		document.getElementById(div1).scrollTop += x;
	}
}

function stopDiv (moving) {
	if (moving) {
		window.clearInterval(moving);
	}
}



function activateFlash (flashBanner, flashVars, bgcol, trans, FLASHMX_WIDTH, FLASHMX_HEIGHT) {
	document.write("<OBJECT CLASSID=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" CODEBASE=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0\" WIDTH=" + FLASHMX_WIDTH + " HEIGHT=" + FLASHMX_HEIGHT + ">");
	document.write("<PARAM NAME=\"movie\" VALUE=\"" + flashBanner + "\">");
	document.write("<PARAM NAME=\"FlashVars\" VALUE=\"" + flashVars + "\">");
	document.write("<PARAM NAME=\"quality\" VALUE=\"high\">");
	if (bgcol != "") document.write("<PARAM NAME=\"bgcolor\" VALUE=\"" + bgcol + "\">");
	document.write("<PARAM NAME=\"menu\" VALUE=\"false\">");
	if (trans) document.write("<PARAM NAME=\"wmode\" VALUE=\"transparent\">");
	document.write("<EMBED SRC=\"" + flashBanner + "\" MENU=\"false\"");
	document.write(" FlashVars=\"" + flashVars + "\"");
	if (bgcol != "") document.write(" BGCOLOR=\"" + bgcol + "\"");
	document.write(" QUALITY=\"high\" PLUGINSPAGE=\"http://www.macromedia.com/go/getflashplayer\" TYPE=\"application/x-shockwave-flash\" WIDTH=" + FLASHMX_WIDTH + " HEIGHT=" + FLASHMX_HEIGHT);
	if (trans) document.write(" WMODE=\"transparent\"");
	document.write(">");
	document.write("</EMBED>");
	document.write("</OBJECT>");
}
