function ValidateContact()
{
	var x;
	var alertmsg;
	x=0;
	alertmsg = "The following fields are required: \n";
	if (document.getElementById("ename").value==""){alertmsg = alertmsg + "\nName";x = x + 1;}
	if (document.getElementById("eemail").value==""){alertmsg = alertmsg + "\nEmail";x = x + 1;}
	if (document.getElementById("esubject").value==""){alertmsg = alertmsg + "\nSubject";x = x + 1;}
	if (document.getElementById("ebody").value==""){alertmsg = alertmsg + "\nBody";x = x + 1;}
	if (x == 0){document.getElementById("contactform").submit();}
	else{alert(alertmsg);return false;}	
}

function ValidateMember()
{
	var x;
	var alertmsg;
	x=0;
	alertmsg = "The following fields are required: \n";
	if (document.getElementById("company").value == ""){alertmsg = alertmsg + "\nCompany";x = x + 1;}
	if (document.getElementById("type").value == ""){alertmsg = alertmsg + "\nType";x = x + 1;}
	if (document.getElementById("address1").value == ""){alertmsg = alertmsg + "\nAddress1";x = x + 1;}
	if (document.getElementById("city").value == ""){alertmsg = alertmsg + "\nCity";x = x + 1;}
	if (document.getElementById("state").value == ""){alertmsg = alertmsg + "\nState";x = x + 1;}
	if (document.getElementById("zip").value == ""){alertmsg = alertmsg + "\nZip";x = x + 1;}
	if (document.getElementById("phone").value == ""){alertmsg = alertmsg + "\nPhone";x = x + 1;}
	if (document.getElementById("email").value == ""){alertmsg = alertmsg + "\nEmail";x = x + 1;}
	if (document.getElementById("contact").value == ""){alertmsg = alertmsg + "\nContact";x = x + 1;}
	if (document.getElementById("text").value == ""){alertmsg = alertmsg + "\nAbout";x = x + 1;}
	if (x == 0){document.getElementById("memberform").submit();}
	else{alert(alertmsg);return false;}
}

function ValidateRegistration()
{
	var x;
	var alertmsg;
	x=0;
	alertmsg = "The following fields are required: \n";
	if (document.getElementById("contact").value == ""){alertmsg = alertmsg + "\nName";x = x + 1;}
	if (document.getElementById("address1").value == ""){alertmsg = alertmsg + "\nAddress1";x = x + 1;}
	if (document.getElementById("city").value == ""){alertmsg = alertmsg + "\nCity";x = x + 1;}
	if (document.getElementById("state").value == ""){alertmsg = alertmsg + "\nState";x = x + 1;}
	if (document.getElementById("zip").value == ""){alertmsg = alertmsg + "\nZip";x = x + 1;}
	if (document.getElementById("phone").value == ""){alertmsg = alertmsg + "\nPhone";x = x + 1;}
	if (document.getElementById("email").value == ""){alertmsg = alertmsg + "\nEmail";x = x + 1;}
	if (x == 0){document.getElementById("registerform").submit();}
	else{alert(alertmsg);return false;}
}

function popup(mypage, myname, w, h, scroll) 
{
	var winl = (screen.width - w) / 2;
	var wint = (screen.height - h) / 2;
	winprops = 'height='+h+',width='+w+',top='+wint+',left='+winl+',scrollbars='+scroll+',resizable'
	win = window.open(mypage, myname, winprops)
	if (parseInt(navigator.appVersion) >= 4) 
	{ 
		win.window.focus(); 
	}
}