// Main Site Java Script
// (w) 2006 Mark Beazley
// Davis Audio Visual, LLC

if (!document.getElementById)  { 
	window.location = "badbrowser.htm";
	}
	
var currentmenu = null;
var screenwidth = screen.availWidth;
var screenheight = screen.availHeight;
var base = "http://www.davisav.com/";

function menuon(menuid,actionid) {
	if (!document.getElementById) return null;
	var menu = document.getElementById(menuid);
	var action = document.getElementById(actionid);
	if (menu == null) return;
	// menu.style.left = action.offsetwidth + "px";
    menu.style.top = action.offsetTop + "px";
	menu.style.visibility = "visible";
	return menuid;
	}

function menuoff(menuid) {
	if (!document.getElementById) return null;
	if (menuid == null) return;
	menu = document.getElementById(menuid);
	if (menu == null) return;
	menu.style.visibility = "hidden";
	}
                
function classchanger(objid,newclass,lastid,oldclass,skip) {
    if (lastid == objid) return lastid;
    document.getElementById(objid).className = newclass;
    if (lastid != skip) {
        document.getElementById(lastid).className = oldclass;
        }
    return objid;
    }