<!--
	function winpopup(value){
	var url="http://www.rajtourism.com/registrationregistration/registration/group_mail.asp?"+value
	wo=window.open(url, "paintings", "width=450, height=320, resizable, status")
	wo.moveTo(25,25)
	wo.focus()
	}

/////////////////////////////

	var whitespace = " \t\n\r";
    var defaultEmptyOK = false;

	function isEmpty(s){ 
	return ((s == null) || (s.length == 0))
	}

	function isWhitespace (s){
	var i;
	// Is s empty?
	if (isEmpty(s)) return true;
	
	// Search through string's characters one by one
	// until we find a non-whitespace character.
	// When we do, return false; if we don't, return true.
 	for (i = 0; i < s.length; i++){   
	// Check that current character isn't whitespace.
	var c = s.charAt(i);
	if (whitespace.indexOf(c) == -1) return false;
	}
	
	// All characters are whitespace.
	return true;
	}

	function isEmail (s){
	if (isEmpty(s))
	// is s whitespace?
	if (isWhitespace(s)) return false;
	// there must be >= 1 character before @, so we
	// start looking at character position 1
	// (i.e. second character)
	var i = 1;
	var sLength = s.length;
	// look for @
	while ((i < sLength) && (s.charAt(i) != "@")){
	i++
	}
    
	if ((i >= sLength) || (s.charAt(i) != "@")) 
	return false;
	else i += 2;
 
	// look for .
	while ((i < sLength) && (s.charAt(i) != ".")){
	i++
	}
	
	// there must be at least one character after the .
	if ((i >= sLength - 1) || (s.charAt(i) != ".")) return false;
	else return true;
	}
	
	function isCharsInBag (s, bag){  
    var i;
    // Search through string's characters one by one.
    // If character is in bag, append to returnString.

    for (i = 0; i < s.length; i++){ 
    // Check that current character isn't whitespace.
    var c = s.charAt(i);
    if (bag.indexOf(c) == -1) return false;
    }
    return true;
	}

	function ValidateUser(){

	var email = document.registration.t_email.value = document.registration.t_email.value.toLowerCase();
		
	if (isWhitespace(document.registration.t_fname.value)){
	alert("Please Provide First Name !");
	document.registration.t_fname.focus();
	return false;
	}
	
	if (isWhitespace(document.registration.t_lname.value)){
	alert("Please Provide Last Name !");
	document.registration.t_lname.focus();
	return false;
	}
	
	if (isWhitespace(document.registration.t_addo.value)){
	alert("Please Porvide Your Address !");
	document.registration.t_addo.focus();
	return false;
	}
	
	if (isWhitespace(document.registration.t_city.value)){
	alert("Please Provide Your City Name !");
	document.registration.t_city.focus();
	return false;
	}
	
	if (document.registration.t_country.options[document.registration.t_country.selectedIndex].value == 0){
	alert("Please, Select Your Country !");
  	document.registration.t_country.focus();
	return false;
	}
	
	if (document.registration.t_dob_month.options[document.registration.t_dob_month.selectedIndex].value == 0){
	alert("Please, Select Month Of Your Birth !");
  	document.registration.t_dob_month.focus();
	return false;
	}
	
	if (document.registration.t_dob_day.options[document.registration.t_dob_day.selectedIndex].value == 0){
	alert("Please, Select Day Of Your Birth !");
  	document.registration.t_dob_day.focus();
	return false;
	}
	
	if (document.registration.t_dob_year.options[document.registration.t_dob_year.selectedIndex].value == 0){
	alert("Please, Select Year Of Your Birth !");
  	document.registration.t_dob_year.focus();
	return false;
	}
	
	if (isWhitespace(document.registration.t_tel_country_code.value)){
	alert("Please Insert Your Telephone Country Code !");
	document.registration.t_tel_country_code.focus();
	return false;
	}
	
	if (isWhitespace(document.registration.t_tel_area_code.value) || (isNaN(document.registration.t_tel_area_code.value))){
	alert("Please Insert A Valid Telephone Area Code !");
	document.registration.t_tel_area_code.select();
	return false;
	}

	if (isWhitespace(document.registration.t_telno.value) || (isNaN(document.registration.t_telno.value))){
	alert("Please Insert A Valid Telephone Number !");
	document.registration.t_telno.select();
	return false;
	}
	
	if (!isWhitespace(document.registration.t_fax_area_code.value) && (isNaN(document.registration.t_fax_area_code.value))){
	alert("Please Insert A Valid Fax Area Code !");
	document.registration.t_fax_area_code.select();
	return false;
	}

	if (!isWhitespace(document.registration.t_faxno.value) && (isNaN(document.registration.t_faxno.value))){
	alert("Please Insert A Valid Telephone Number !");
	document.registration.t_faxno.select();
	return false;
	}
	
	if (!isEmail(email)){
	alert( "Please Insert A Valid Email Address !");
	document.registration.t_email.select();
	return false;
    }
	
	if (document.registration.t_currency.options[document.registration.t_currency.selectedIndex].value == 0){
	alert("Please, Select Your Preferred Currency For Search !");
  	document.registration.t_currency.focus();
	return false;
	}
	
	var login = document.registration.t_login.value;

	if (isWhitespace(document.registration.t_login.value)){
	alert("Please Insert A Login !");
	document.registration.t_login.focus();
	return false;
	}
	
	if (!isCharsInBag( login, "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.-_" )){
	alert("Login May Only Contain The Following Characters:\nABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.-_" );
	document.registration.t_login.select();
	document.registration.t_login.focus(); 
	return false;
	}
    
	else if ( !isCharsInBag( login.charAt(login.length - 1), "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789")){
	alert("Login Must End In An Alphanumeric Character !");
	document.registration.t_login.select();
	document.registration.t_login.focus(); 
	return false;
	}

	else if (!isCharsInBag( login.charAt(0), "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789") ){
	alert("Login Must Start With An Alphanumeric Character !");
	document.registration.t_login.select();
	document.registration.t_login.focus(); 
	return false;
	}

	else if (document.registration.t_login.value != "" && document.registration.t_login.value.length < 3){
   	alert( "Please Insert A Login Between 3 - 8 Characters !");
	document.registration.t_login.select();
	document.registration.t_login.focus(); 
	return false;
    }
	
	if (isWhitespace(document.registration.t_passo.value)){
	alert("Please Insert A Password !");
	document.registration.t_passo.select();
	document.registration.t_passo.focus();
	return false;
	}
	
	else if (document.registration.t_passo.value != "" && document.registration.t_passo.value.length < 3){
   	alert( "Please Insert A Password Between 3 - 12 Characters !");
	document.registration.t_passo.select();
	document.registration.t_passo.focus(); 
	return false;
    }
	
	if (document.registration.t_passo.value != document.registration.t_passt.value){
	alert( "Your Passwords Do Not Match. Please Retype And Try Again !");
	document.registration.t_passt.select();
	document.registration.t_passt.focus();
	return false;
	}
	
	if (document.registration.t_pass_id.options[document.registration.t_pass_id.selectedIndex].value == 0){
	alert("Please, Select A Question For Retriveing Password !");
  	document.registration.t_pass_id.focus();
	return false;
	}
	
	if (isWhitespace(document.registration.t_answer.value)){
	alert("Please Insert A Answer To The Question !");
	document.registration.t_answer.select();
	document.registration.t_answer.focus();
	return false;
	}
			
	return true;
	}

//-->
