function $(id) { return document.getElementById(id); }

function btnHome_(state)
{
	var clr = '';
	state == 0 ? clr = '#337033' : clr = '#33A733';
	$('btnHome').style.backgroundColor = clr; 
}

function parseLists()
{
	if (document.all&&document.getElementById) {
		menuRoot = $('menu');
		searchForLIs(menuRoot);
 	} 	
}

function searchForLIs(objectReference)
{
	for (var i=0; i < objectReference.childNodes.length; i++) {
		node = objectReference.childNodes[i];
		switch (node.nodeName) {
			case "LI": {
				node.onmouseover = function() {
					this.className += " over";
  				}
  				node.onmouseout = function() {
  					this.className = this.className.replace(" over", "");
   				}
				searchForLIs(node);	
				break;
			}
			case "UL": {
				searchForLIs(node);
				break;
			}		
		}
	}
	return;
}
