<!--
function check_form(the_form) {
	var errors="";
	var boRadioChecked;
	
	//-------------   Question A   ----------------
	for (var i=0; i < the_form.a.length; i++) {
		if(the_form.a[i].checked) {
			boRadioChecked = true;
		}
	}
	if(!boRadioChecked) {
		errors+="Please select an answer for question A.\n";
	}
	if(the_form.a[4].checked) {
		//other field is selected
		if(the_form.a_1.value=="") {
			errors+="You must state 'other' for question A.\n"
		}
	}
	boRadioChecked = false;
	//---------------------------------------------
	//-------------   Question B   ----------------
	for (var i=0; i < the_form.b.length; i++) {
		if(the_form.b[i].checked) {
			boRadioChecked = true;
		}
	}
	if(!boRadioChecked) {
		errors+="Please select an answer for question B.\n";
	}
	boRadioChecked = false;
	//---------------------------------------------
	//-------------   Question C   ----------------
	if(the_form.c.options[the_form.c.selectedIndex].value=="") {
		errors+="Please select your age-group in question C.\n";
	}
	//---------------------------------------------
	//-------------   Question D   ----------------
	
	if(
		the_form.d_1.checked + 
	  	the_form.d_2.checked +
		the_form.d_3.checked +
		the_form.d_4.checked +
		the_form.d_5.checked +
		the_form.d_6.checked +
		the_form.d_7.checked +
		the_form.d_8.checked +
		the_form.d_9.checked +
		the_form.d_10.checked +
		the_form.d_11.checked == 0 
	   ) 
	   { errors+="Please select an option on question D.\n"; }
	   
	   if(the_form.d_11.checked) {
	   		if(the_form.d_11_1.value=="") {
	   			errors+="You must state 'other' for question D.\n";
			}
	   }
	//---------------------------------------------
	//-------------   Question E   ----------------
	
	for (var i=0; i < the_form.e.length; i++) {
		if(the_form.e[i].checked) {
			boRadioChecked = true;
		}
	}
	if(!boRadioChecked) {
		errors+="Please select an answer for question E.\n";
	}
	boRadioChecked = false;
	//---------------------------------------------
	//-------------   Question F   ----------------
	for (var i=0; i < the_form.f.length; i++) {
		if(the_form.f[i].checked) {
			boRadioChecked = true;
		}
	}
	if(!boRadioChecked) {
		errors+="Please select an answer for question F.\n";
	}
	boRadioChecked = false;
	//---------------------------------------------
	//-------------   Question G   ----------------
	for (var i=0; i < the_form.g.length; i++) {
		if(the_form.g[i].checked) {
			boRadioChecked = true;
		}
	}
	if(!boRadioChecked) {
		errors+="Please select an answer for question G.\n";
	}
	boRadioChecked = false;
	//---------------------------------------------
	//-------------   Question H   ----------------
	if(the_form.h.value=="") {
		the_form.h.value="Nothing specified.";
	}
	//---------------------------------------------
	//-------------   Question I   ----------------
	if(the_form.i.value=="") {
		the_form.i.value="Nothing specified.";
	}
	//---------------------------------------------
	
	if(errors) {
		alert(errors);
		return false;
	}
	return true;
	
}
//-->
