// JavaScript Document
function toggleDisplay(obj){
		var el = document.getElementById(obj);
		if (el.style.display == 'none' || !el.style.display) {
			//safe function to show an element with a specified id
			if(navigator.appName.indexOf("Microsoft") > -1){
				var tog = 'block'
			} else {
				var tog = 'table-row';
			}
		} else {
				var tog = 'none';
		}
		//safe function to toggle an element with a specified id
		if (document.getElementById) { // DOM3 = IE5, NS6
			document.getElementById(obj).style.display = tog;
		}
		else {
			if (document.layers) { // Netscape 4
				document.obj.display = tog;
			}
			else { // IE 4
				document.all.obj.style.display = tog;
			}
		}
}
function show(obj){
		var el = document.getElementById(obj);
		
		if(navigator.appName.indexOf("Microsoft") > -1){
			var tog = 'block'
		} else {
			var tog = 'table-row';
		}

		//safe function to toggle an element with a specified id
		if (document.getElementById) { // DOM3 = IE5, NS6
			document.getElementById(obj).style.display = tog;
		}
		else {
			if (document.layers) { // Netscape 4
				document.obj.display = tog;
			}
			else { // IE 4
				document.all.obj.style.display = tog;
			}
		}
}

function hide(obj){
		var el = document.getElementById(obj);
		var tog = 'none';
		
		//safe function to toggle an element with a specified id
		if (document.getElementById) { // DOM3 = IE5, NS6
			document.getElementById(obj).style.display = tog;
		}
		else {
			if (document.layers) { // Netscape 4
				document.obj.display = tog;
			}
			else { // IE 4
				document.all.obj.style.display = tog;
			}
		}
}

function validateFields(){
	if(window.assessForm.yourName.value == "" || window.assessForm.yourCompany.value == "" ){
		window.alert('Please fill in your name and company.');
	} else {
		window.assessForm.submit();
	}
}
function submitForm(){
	window.assessForm.submit();
}
