function validate(q){
var oInputArray = new Array();
var sH='';
		
		q.Band_Name.style.backgroundColor = 'White';
	if ((!q.Band_Name.value.length)) {
		 oInputArray.push("Please enter the Band Name \n");		
		q.Band_Name.style.backgroundColor = 'Yellow';		
	}	
		
		q.Band_Contact_Confirm.style.backgroundColor = 'White';
	if ((!q.Band_Contact_Confirm.checked)) {
		 oInputArray.push("Please check the band contact confirmation box \n");		
		q.Band_Contact_Confirm.style.backgroundColor = 'Yellow';		
	}
		q.Band_Contact_FName.style.backgroundColor = 'White';
	if ((!q.Band_Contact_FName.value.length)) {
		 oInputArray.push("Please enter the Band Contact's First Name \n");		
		q.Band_Contact_FName.style.backgroundColor = 'Yellow';		
	}
		q.Band_Contact_LName.style.backgroundColor = 'White';
	if ((!q.Band_Contact_LName.value.length)) {
		 oInputArray.push("Please enter the Band Contact's Last Name \n");		
		q.Band_Contact_LName.style.backgroundColor = 'Yellow';		
	}
		q.Band_Password.style.backgroundColor = 'White';
	if ((!q.Band_Password.value.length)) {
		oInputArray.push("Please enter a Password \n");
		q.Band_Password.style.backgroundColor = 'Yellow';				
	}		
		q.Cfm_Password.style.backgroundColor = 'White';		
	if ((!q.Cfm_Password.value.length)) {
		 oInputArray.push("Please enter a Confirmation Password \n");
		q.Cfm_Password.style.backgroundColor = 'Yellow';		
	}	
		
		q.Band_City.style.backgroundColor = 'White';
	if ((!q.Band_City.value.length)) {
		 oInputArray.push("Please enter your City \n");
		q.Band_City.style.backgroundColor = 'Yellow';
	}
		q.Band_State.style.backgroundColor = 'White';
	if ((!q.Band_State.value.length)) {
		 oInputArray.push("Please select your State \n");
		q.Band_State.style.backgroundColor = 'Yellow';	
	}	
		q.Band_Zip.style.backgroundColor = 'White';
	if ((!q.Band_Zip.value.length)) {
		 oInputArray.push("Please enter your ZIP Code \n");
		q.Band_Zip.style.backgroundColor = 'Yellow';	
	}
		q.Band_Tel.style.backgroundColor = 'White';
	if (q.Band_Tel.value.length != 14 ) {
		 oInputArray.push("Please enter your Area Code & Telephone Number Code \n");
		q.Band_Tel.style.backgroundColor = 'Yellow';	
	}
		q.month.style.backgroundColor = 'White';		
	if ((!q.month.value.length)) {
		oInputArray.push("Please select a Month \n");
		q.month.style.backgroundColor = 'Yellow';		
	}
		q.day.style.backgroundColor = 'White';
	if ((!q.day.value.length)) {
		 oInputArray.push("Please select a Day \n");
		q.day.style.backgroundColor = 'Yellow';
	}
		q.year.style.backgroundColor = 'White';
	if ((!q.year.value.length)) {
		 oInputArray.push("Please select a Year \n");
		q.year.style.backgroundColor = 'Yellow';	
	}
		q.Band_of_Age.style.backgroundColor = 'White';
	if ((!q.Band_of_Age.checked)) {
		 oInputArray.push("Please confirm that you are 18 or over \n");
		q.Band_of_Age.style.backgroundColor = 'Yellow';
	}
		q.Band_Rights.style.backgroundColor = 'White';
	if ((!q.Band_Rights.checked)) {
		 oInputArray.push("Please confirm that you have the publishing rights to your bands music \n");
		q.Band_Rights.style.backgroundColor = 'Yellow';
	}
		q.Band_Terms.style.backgroundColor = 'White';
	if ((!q.Band_Terms.checked)) {
		 oInputArray.push("Please confirm that you Agree to the Terms & Conditions \n");
		q.Band_Terms.style.backgroundColor = 'Yellow';
	}
	
	if (q.Band_Password.value != q.Cfm_Password.value) {
	     oInputArray.push("\nThe Password entries do not match. Please re-enter.\n");
		 q.Band_Password.style.backgroundColor = 'Red';
		 q.Cfm_Password.style.backgroundColor = 'Red';        
	}
	//email verification
		var at="@";
		var dot=".";
		var lat=q.Band_Email.value.indexOf(at);
		var lstr=q.Band_Email.value.length;
		var ldot=q.Band_Email.value.indexOf(dot);
		
			q.Band_Email.style.backgroundColor = 'White';
		if (q.Band_Email.value.indexOf(at)==-1){
		   oInputArray.push("Invalid E-mail ID \n");
		   q.Band_Email.style.backgroundColor = 'Yellow';
		}
			
		if (q.Band_Email.value.indexOf(at)==-1 || q.Band_Email.value.indexOf(at)==0 || q.Band_Email.value.indexOf(at)==lstr){
		   oInputArray.push("Invalid E-mail ID \n");
		   q.Band_Email.style.backgroundColor = 'Yellow';
		  }
			
		if (q.Band_Email.value.indexOf(dot)==-1 || q.Band_Email.value.indexOf(dot)==0 || q.Band_Email.value.indexOf(dot)==lstr){
		    oInputArray.push("Invalid E-mail ID \n");
			q.Band_Email.style.backgroundColor = 'Yellow';
		}
			
		 if (q.Band_Email.value.indexOf(at,(lat+1))!=-1){
		    oInputArray.push("Invalid E-mail ID \n");
			q.Band_Email.style.backgroundColor = 'Yellow';
		 }
			
		 if (q.Band_Email.value.substring(lat-1,lat)==dot || q.Band_Email.value.substring(lat+1,lat+2)==dot){
		    oInputArray.push("Invalid E-mail ID \n");
			q.Band_Email.style.backgroundColor = 'Yellow';
		 }
			
		 if (q.Band_Email.value.indexOf(dot,(lat+2))==-1){
		    oInputArray.push("Invalid E-mail ID \n");
			q.Band_Email.style.backgroundColor = 'Yellow';
		 }
				
		 if (q.Band_Email.value.indexOf(" ")!=-1){
		    oInputArray.push("Invalid E-mail ID \n");
			q.Band_Email.style.backgroundColor = 'Yellow';
		 }

 				
		sH = oInputArray.join(' ');
		if ((sH.length > 0)) {
     	alert(sH); 
		return(false);
		}
		return(true);		
}