function checkCourseForm(theSelect) {
if ((document.bookingform.locID[document.bookingform.locID.selectedIndex].value=="0") | (document.bookingform.catID[document.bookingform.catID.selectedIndex].value=="0")) {
  document.bookingform.schedName.selectedIndex = 0;
  document.bookingform.schedName.disabled = true;
  document.bookingform.schedID.selectedIndex = 0;
  document.bookingform.schedID.disabled = true;

} else if ((theSelect.name == 'schedName') | (theSelect.name == 'locID') | (theSelect.name == 'catID') ) {
  if ((theSelect.name == 'locID') | (theSelect.name == 'catID')) {
    document.bookingform.schedName.selectedIndex = 0;
  }
  document.bookingform.schedID.selectedIndex = 0;
  document.bookingform.submit();
} else {
  document.bookingform.submit();
}}

function submitCourseForm(theForm) {
	//if (theForm.locID[theForm.locID.selectedIndex].value=="0") {
	//alert("Please select a location to continue.");
	//theForm.locID.focus();
	//return(false);
	//}
	//if (theForm.catID[theForm.catID.selectedIndex].value=="0") {
	//alert("Please select a course category to continue.");
	//theForm.catID.focus();
	//return(false);
	//}
	//if (theForm.schedName.value=="") {
	//alert("Please select a course to continue.");
	//theForm.schedName.focus();
	//return(false);
	//}
	//if (theForm.schedID.value=="") {
	//alert("Please select a schedule date to continue.");
	//theForm.schedID.focus();
	//return(false);
	//}
  document.bookingform.submit();
}

function submitTrainingForm(theForm) {
	if (theForm.locID[theForm.locID.selectedIndex].value=="0") {
	alert("Please select a location to continue.");
	theForm.locID.focus();
	return(false);
	}
	if (theForm.catID[theForm.catID.selectedIndex].value=="0") {
	alert("Please select a course category to continue.");
	theForm.catID.focus();
	return(false);
	}
  document.bookingform.submit();
}

function submitConsultantForm(theForm) {
	if (theForm.locID[theForm.locID.selectedIndex].value=="0") {
	alert("Please select a location to continue.");
	theForm.locID.focus();
	return(false);
	}
	if (theForm.catID[theForm.catID.selectedIndex].value=="0") {
	alert("Please select a course category to continue.");
	theForm.catID.focus();
	return(false);
	}
	if (theForm.service[theForm.service.selectedIndex].value=="0") {
	alert("Please select the service required.");
	theForm.service.focus();
	return(false);
	}
  document.bookingform.submit();
}

function submitFacilityForm(theForm) {
	if (theForm.locID[theForm.locID.selectedIndex].value=="0") {
	alert("Please select a location to continue.");
	theForm.locID.focus();
	return(false);
	}
  document.bookingform.submit();
}

function validateScheduleForm(theForm) {
if (theForm.schedID.value=="0"){
		alert("Please select a course date & location to continue.");
		theForm.schedID.focus();
		return(false);
	}
	return(true);
	}
