<!--
// #### allowing frames for roltanet ####
if (self != top) {
	if (document.images)
		top.location.replace(window.location.href);
	else
		top.location.href = window.location.href;
}

// #### clear form ### 
function cls(str){
	str.value = "";
	return;
}

var opened=false;
var win;
function openWin(str,nm,width,height){
	if(opened == false){
		win = open(str,nm,"status=0,scrollbars=1,menubar=0,toolbar=0,location=0,resizeable=0,width="+width+",height="+height);
	}
	else if(opened == true){
		if(win.closed == false)
		win.close(); 
		win = window.open(str,nm,"status=0,scrollbars=1,menubar=0,toolbar=0,location=0,resizeable=0,width="+width+",height="+height);    
	}
	opened = true; 
}

function setStat(str){
	window.status=str;
	window.defaultStatus="";
}

function veriPopUp(url) { sealWin=window.open(url,"win",'toolbar=0,location=0,directories=0,status=1,menubar=1,scrollbars=1,resizable=1,width=720,height=450'); self.name = "mainWin"; }



function age_diff_max(){

	var diff = parseInt(document.quicksearch.ageto.options[document.quicksearch.ageto.selectedIndex].text) - parseInt(document.quicksearch.agefrom.options[document.quicksearch.agefrom.selectedIndex].text);
	if(diff > 10) {
		alert("Age range exceeds 10 years.\nChange age range or use Advanced Search");
		return false;
	}
	else if(parseInt(document.quicksearch.ageto.options[document.quicksearch.ageto.selectedIndex].text) < parseInt(document.quicksearch.agefrom.options[document.quicksearch.agefrom.selectedIndex].text)){
		alert("Invalid From & To Age");
		return false;
	}
	else {
	return true;
	}
}
function chk_community(){
	if (document.quicksearch.community.options[document.quicksearch.community.selectedIndex].value == ""){
		alert("Please select Community");
		return false;
	}else{
		return true;
	}
}

function chk_quicksearch(){
	if (age_diff_max() == true){
		return	chk_community();
	}
	else{
		return false;
	}	
}
//-->
