// JavaScript Document
//Encrypted Password script- By Rob Heslop
//Script featured on Dynamic Drive 
//Visit http://www.dynamicdrive.com 

function submitentry(){
	password = document.password1.password2.value.toLowerCase();
	username = document.password1.username2.value.toLowerCase();
	//register = document.password1.register.value.toLowerCase();
	//register = document.getElementById("member");
	passcode = 1;
	usercode = 1;
	for(i = 0; i < password.length; i++) {
	passcode *= password.charCodeAt(i);
	}
	for(x = 0; x < username.length; x++) {
	usercode *= username.charCodeAt(x);
	}
	if (password != '' && username != '') {
	if (document.getElementById("member").checked==true) {
		//CHANGE THE NUMBERS BELOW TO REFLECT YOUR USERNAME/PASSWORD
		if(usercode==247745381345280&&passcode==2390188171333248000)
		//CHANGE THE NUMBERS ABOVE TO REFLECT YOUR USERNAME/PASSWORD
		{
		window.location=password+".htm";
		return;}
		else{
		alert("password/username combination wrong");
		}
	}
	if (document.getElementById("volunteer").checked==true) {
		//CHANGE THE NUMBERS BELOW TO REFLECT YOUR USERNAME/PASSWORD
		if(usercode==1771818073200&&passcode==140596207118640)
		//CHANGE THE NUMBERS ABOVE TO REFLECT YOUR USERNAME/PASSWORD
		{
		window.location=password+".htm";
		return;}
		else{
		alert("password/username combination wrong");
		}
	}
	}else{
		alert("please enter your username and password");
		}
}
