////////// Generic Form Validation
function validate(){

		function check(){
		for (i=0; i<document.forms[0].elements.length; i++){
			if(!document.forms[0].elements[i].value){
				alert('please fill in all required fields.');
				return false;
				}
			}
		return true
		}
	document.forms[0].onsubmit = check;
	}



window.onload = validate;
