<!--
startList = function()
{
	if(document.all && document.getElementById)
	{
		navRoot = document.getElementById("nav");
		for(i=0; i<navRoot.childNodes.length; i++)
		{
			node = navRoot.childNodes[i];
			if(node.nodeName == "LI")
			{
				node.onmouseover = function(){
					this.className += " over";
				}
				node.onmouseout = function(){
					this.className = this.className.replace(" over", "");
				}
			}
		}
	}
}

function checkWholeForm(formobj)
{
	var errorMsg = '';
	var numErrors = 0;
	
	for(var i=0; i < fieldRequired.length; i++){
		var obj = formobj.elements[fieldRequired[i]];
		if(obj)
		{
			if(obj.type == "checkbox"){
				if(!obj.checked){errorMsg += ' - ' + fieldDescription[i] + '\n'; numErrors++;}
			}
			else if(obj.type == "select-one"){
				if(obj.selectedIndex == -1 || obj.options[obj.selectedIndex].value == ""){errorMsg += ' - ' + fieldDescription[i] + '\n'; numErrors++;}
			}
			else if(obj.type == "select-multiple"){
				if(obj.selectedIndex == -1){errorMsg += ' - ' + fieldDescription[i] + '\n'; numErrors++;}
			}
			else if(obj.type == "text" || obj.type == "textarea"){
				if(obj.value == "" || obj.value == null){errorMsg += ' - ' + fieldDescription[i] + '\n'; numErrors++;}
				else if(SelectEmail[i] == 1 && (obj.value.indexOf('@') == -1 || obj.value.indexOf('.') == -1)){errorMsg += ' - ' + "A valid e-mail address must contain both '@' and '.'" + '\n'; numErrors++;}
			}
			else{
				if(SelectRadio[i] == 1){
					var radio_choice = 0;
					for (m = 0; m < obj.length; m++){if(obj[m].checked){radio_choice = 1;}}
					if(radio_choice == 0){errorMsg += ' - ' + fieldDescription[i] + '\n'; numErrors++;}
				}
				else if(SelectCheck[i] == 1){
					var checkbox_choice = 0;
					for (m = 0; m < obj.length; m++){if(obj[m].checked){checkbox_choice = 1;}}
					if(checkbox_choice == 0){errorMsg += ' - ' + fieldDescription[i] + '\n'; numErrors++;}
				}
				else if(obj.value == "" || obj.value == null){errorMsg += ' - ' + fieldDescription[i] + '\n'; numErrors++;}
			}
		}
	}

	if(numErrors > 0){
		if(numErrors > 1)
		{
			alert('\nPlease complete the following fields:\n' + errorMsg);
		}
		else
		{
			alert('\nPlease complete the following field:\n' + errorMsg);
		}
		
		return false;
	}
    return true;
}

window.onload = startList;
//-->