function cascadeCountry(value) {
	
   if (document.getElementById("txtstateprovince") != null) {
	   
	if (value != '') {
		
		http.open('get', 'cascade_sign.php?a=country&v=' + value );
	    document.getElementById('txtstateprovince').innerHTML = "&nbsp;&nbsp;" + loadingTag;
	    http.onreadystatechange = handleResponse;
	    http.send(null);
		
	}
   }
}

function cascadeState(value,v1) {
	
	
   if (true) {
   
   		http.open('get', 'cascade_sign.php?a=state&v=' + value  + '&v1=' + v1);
		
	   /* remove the county field in target references, the default refrerences
		   for changing state is county and state */
	   
	   //document.getElementById('txtcounty').innerHTML="&nbsp;&nbsp;"+loadingTag;
	
		document.getElementById('txtcity').innerHTML="&nbsp;&nbsp;"+loadingTag;
	
    	http.onreadystatechange = handleResponse;
		
    	http.send(null);
		
   }
}

function cascadeCounty(value,v1,v2) {
   
   if (document.getElementById("txtcity") != null) {
     http.open('get', 'cascade_sign.php?a=county&v=' + value
					+ '&v1=' + v1 + '&v2=' + v2);
	document.getElementById('txtcity').innerHTML="&nbsp;&nbsp;"+loadingTag;
     http.onreadystatechange = handleResponse;
     http.send(null);
   }
   
}

function cascadeCity(value,v1,v2,v3) {
   if (document.getElementById("txtzip") != null) {
      http.open('get', 'cascade_sign.php?a=city&v=' + value
					+ '&v1=' + v1 + '&v2=' + v2 + '&v3=' + v3);
	document.getElementById('txtzip').innerHTML="&nbsp;&nbsp;"+loadingTag;
      http.onreadystatechange = handleResponse;
      http.send(null);
   }
}

function cascadeCountryL(value) {
   if (document.getElementById("txtlookstateprovince") != null) {
      http.open('get', 'cascade_sign2.php?a=country&v=' + value );
	document.getElementById('txtlookstateprovince').innerHTML="&nbsp;&nbsp;"+loadingTag;
      http.onreadystatechange = handleResponse;
      http.send(null);
   }
}

function cascadeStateL(value,v1) {
	
   if (true) {
	   
      	http.open('get', 'cascade_sign2.php?a=state&v=' + value  + '&v1=' + v1);
	  
	  	/* remove the county field in target references, the default refrerences
		   for changing state is county and state */
	   
	   	//document.getElementById('txtlookcounty').innerHTML="&nbsp;&nbsp;"+loadingTag;
	
		document.getElementById('txtlookcity').innerHTML="&nbsp;&nbsp;"+loadingTag;
      	
		http.onreadystatechange = handleResponse;
      	
		http.send(null);
   
   }
}

function cascadeCountyL(value,v1,v2) {
   if (document.getElementById("txtlookcity") != null) {
      http.open('get', 'cascade_sign2.php?a=county&v=' + value
					+ '&v1=' + v1 + '&v2=' + v2);
	document.getElementById('txtlookcity').innerHTML="&nbsp;&nbsp;"+loadingTag;
      http.onreadystatechange = handleResponse;
      http.send(null);
   }
}

function cascadeCityL(value,v1,v2,v3) {
   if (document.getElementById("txtlookzip") != null) {
       http.open('get', 'cascade_sign2.php?a=city&v=' + value
					+ '&v1=' + v1 + '&v2=' + v2 + '&v3=' + v3);
	document.getElementById('txtlookzip').innerHTML="&nbsp;&nbsp;"+loadingTag;
       http.onreadystatechange = handleResponse;
       http.send(null);
   }
}
