
function show(id) {
	if (document.getElementById) {
		document.getElementById(id).style.display = "";
		document.getElementById(id).style.zIndex = 1;
	}
	else if (document.all) {
		document.all.item(id).style.visibility = "visible";
		document.all.item(id).zIndex = 1;
	}
	else if (document.layers) {
		document.layers[id].visibility = "show";
		document.layers[id].style.zIndex = 0;
	}
}
function hide(id) {
	if (document.getElementById) {
		document.getElementById(id).style.display = "none";
	}
	else if (document.layers) {
		document.layers[id].visibility = "hide";
	}
	else if (document.all) {
		document.all.item(id).style.visibility = "hidden";
	}
}

var lastid = "";
function Switch(id) {
	if(lastid != "" && lastid != id) hide(lastid);
	lastid = id;
	if (document.getElementById) {
		if(document.getElementById(id).style.display == "none") { show(id); }
		else { hide(id); }
	}
	else if (document.layers) {
		if(document.layers[id].visibility == "hide") { show(id); }
		else { hide(id); }
	}
	else if (document.all) {
		if(document.all.item(id).style.visibility == "hidden") { show(id); }
		else { hide(id); }
	}
}


var menuList = ["pd_menu1","pd_menu2","pd_menu3"];
function pulldownmenu(mObj)
{
	pd_menu = getMenuObj(mObj);
	flag = pd_menu.style.visibility;
	for (i=0; i<menuList.length; i++)
	{
		pd_menu = getMenuObj(menuList[i]);
		pd_menu.style.visibility = "hidden";
	}
	pd_menu = getMenuObj(mObj);
	if (flag == "visible") pd_menu.style.visibility = "hidden"; else pd_menu.style.visibility = "visible";
}
function getMenuObj(obj)
{
	if (document.all) return document.all(obj);
	if (document.getElementById) return document.getElementById(obj);
	return obj;
}
