//функция выделения пункта меню
function onMenu(id, type)
{
	//изменяем верхнюю часть
	document.all(id + "LeftTop").src = (type == 0 ? "images/button_left_top_selected.gif" : "images/button_left_top.gif");
	document.all(id + "Top").className = (type == 0 ? "menu_top_selected" : "menu_top");
	document.all(id + "RightTop").src = (type == 0 ? "images/button_right_top_selected.gif" : "images/button_right_top.gif");
	//изменяем цвет надписи и фон основной части
	document.all(id).className = (type == 0 ? "menu_selected" : "menu");
	//изменяем левую и правую стороны
	document.all(id + "Left").className = (type == 0 ? "menu_side_selected" : "menu_side");
	document.all(id + "Right").className = (type == 0 ? "menu_side_selected" : "menu_side");
	//изменяем нижнюю часть
	document.all(id + "LeftBottom").className = (type == 0 ? "menu_left_bottom_selected.gif" : "menu_left_bottom");
	document.all(id + "Bottom").className = (type == 0 ? "menu_bottom_selected" : "menu_bottom");
	document.all(id + "RightBottom").className = (type == 0 ? "menu_right_bottom_selected.gif" : "menu_right_bottom");
	//открываем пунткты меню
	document.all(id + "Submenu").style.display = (type == 0 ? "block" : "none");

}
