function ValidateRight(){
	
	var regxpEmail = /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/;
	var regxpW = /^([\d\D\s\\.\-]+)$/;
	var regxpD1 = /^(\d\d\d)$/;
	var regxpD2 = /^(\d\d\d\d)$/;
	var regxpZip = /^(\d\d\d\d\d)$/;
	var firstnameRight;
	var addressRight;
	var cityRight;
	var stateRight;
	var zipRight;
	var dayphone_areaRight;
	var dayphone_prefixRight;
	var dayphone_localRight;
	var submit_button;
	var errorRight;
	var labels = new Array("firstnameRight","addressRight","cityRight","stateRight","zipRight","dayPhoneAreaCodeRight");
	var x = this;
	
	function validateFormRight(){
		error_fields = new Array;
		for(var c=0;c<labels.length;c++){
			document.getElementById(labels[c]+"-label").style.color = "#333333";			
		}
		
		if (regxpW.test(x.firstnameRight.value) != true || x.firstnameRight.value == ""){			
			error_fields.push("firstnameRight");
		}
		
		if (regxpW.test(x.addressRight.value) != true || x.addressRight.value == ""){
			error_fields.push("addressRight");
		}
		
		if (regxpW.test(x.cityRight.value) != true || x.cityRight.value == ""){
			error_fields.push("cityRight");
		}
		
		if (regxpW.test(x.stateRight.value) != true || x.stateRight.value == ""){
			error_fields.push("stateRight");
		}
		
		if (regxpZip.test(x.zipRight.value) != true || x.zipRight.value == ""){
			error_fields.push("zipRight");
		}
		
		if (regxpD1.test(x.dayphone_areaRight.value) != true || x.dayphone_areaRight.value == ""){
			error_fields.push("dayPhoneAreaCodeRight");
		}
		
		if (regxpD1.test(x.dayphone_prefixRight.value) != true || x.dayphone_prefixRight.value == ""){
			error_fields.push("dayPhoneAreaCodeRight");
		}
		
		if (regxpD2.test(x.dayphone_localRight.value) != true || x.dayphone_localRight.value == ""){
			error_fields.push("dayPhoneAreaCodeRight");
		}
		
					
		if(error_fields.length != 0){
			x.errorRight.style.display = "block";
			x.errorRight.style.padding = "0";
			x.errorRight.style.margin = "0";
			for(var i=0;i<error_fields.length;i++){
				document.getElementById(error_fields[i]+"-label").style.color = "#FF3300";				
			}
			return false;
		}
		else {
			x.error.style.display = "none";
			document.getElementById("sign-up-right").submit();
		}		
	}
	
	
	this.init = function()
	{
		
		x.firstnameRight = document.getElementById('firstnameRight');
		x.addressRight = document.getElementById('addressRight');
		x.cityRight = document.getElementById('cityRight');
		x.stateRight = document.getElementById('stateRight');
		x.zipRight = document.getElementById('zipRight');
		x.emailRight = document.getElementById('emailRight');	
		x.dayphone_areaRight = document.getElementById('dayPhoneAreaCodeRight');
		x.dayphone_prefixRight = document.getElementById('dayPhoneNumber1Right');
		x.dayphone_localRight = document.getElementById('dayPhoneNumber2Right');
		x.submit_buttonRight = document.getElementById('submit-button-right');
		x.errorRight = document.getElementById('errorRight');
		x.submit_buttonRight.onclick = function() {validateFormRight();return false;}		
	}
}
var validateRight = new ValidateRight();

onloadHandlers[onloadHandlers.length] = "validateRight.init()";