navHover = function() {
	var lis = document.getElementById("navmenu").getElementsByTagName("LI");
	for (var i=0; i<lis.length; i++) {
		lis[i].onmouseover=function() {
			this.className+=" iehover";
		}
		lis[i].onmouseout=function() {
			this.className=this.className.replace(new RegExp(" iehover\\b"), "");
		}
	}
}
if (window.attachEvent) window.attachEvent("onload", navHover);

function synchScrollableTableColumns(table1Id, table2Id, t1HasExtraCol) {
	var table1 = document.getElementById(table1Id);
	var table2 = document.getElementById(table2Id);

	var table1Cells = table1.rows[0].cells;
	var table2Cells = table2.rows[table2.rows.length - 1].cells;

	if (t1HasExtraCol) {
		var diff = table1.clientWidth - table2.clientWidth - 1;

		if (diff >= 0)
			table1Cells[table1Cells.length - 1].style.width = diff;
	}
	else {
		table1.style.width = table2.clientWidth;
	}

	for (var i = 0; i < table2Cells.length; i++) {
		var cell1 = table1Cells[i];
		var cell2 = table2Cells[i];

		cell1.style.width = cell2.clientWidth;
	}
}

function initPage() {
		synchScrollableTableColumns("headtable","datatable", true);
}

function buttonOn(btn) {
	btn.className="buttnon";
}

function buttonOff(btn) {
	btn.className="buttn";
}
