/*
 * AGT JavaScript
 * (c) by Martin Trenkmann
 * webmaster(at)arch-thueringen.de
 * july 2006
 *
 */


window.onload = function()
{
		// install onmouseover event handler for menu items
		var subMenus = document.getElementById("menu").getElementsByTagName("div");
		for (i=0; i != subMenus.length; ++i)
		{
			subMenus[i].onclick = function()
			{
				if (this.id != "selcat")
				{
					var openCat = document.getElementById("opencat");
					if (openCat != null)
					{
						openCat.className = "close";
						openCat.id = "close";
					}
					this.className = "open";
					this.id = "opencat";
				}
			}
			// subMenus[i].onfocus = function() {this.blur()};   // IE sucks !
		}
}


/********************
 ******  Popups *****
 ********************/

function open_popup(url, width, height)
{
	window.open(url, "popup", "width="+width+",height="+height+",left=50,top=50,location=no,menubar=no,resizable=no,scrollbars=yes,status=no,toolbar=no");
}

/*
function open_ausstellung()
{
	window.open("/veranstaltungen/Sonderausstellung.htm","popup","width=680,height=600,left=50,top=50,location=no,menubar=no,resizable=no,scrollbars=yes,status=no,toolbar=no");
}

function open_museum()
{
	window.open("/museum/Museum.htm","popup","width=730,height=600,left=50,top=50,location=no,menubar=no,resizable=no,scrollbars=yes,status=no,toolbar=no");
}
*/

