// whole form check
function checkWholeForm(theForm) {
    var why = "";
	why += checkPlayer(theForm.player.selectedIndex);
	why += checkQuestion(theForm.question.value);
	
	if (why != "") {
		alert("There was a problem with your question:\n\n"+ why);
		return false; 
	}
return true;
}


// individual validation routines
function checkPlayer(choice) {
    var error = "";
    if (choice == 0) {
       error = "You didn't select a player to quiz.\n";
    }    
return error;
} 

function checkQuestion(checkvalue) {
var error = "";
   if (!(checkvalue)) {
       error = "You didn't enter a question.\n";
    }
return error;    
}