
function process(toora)
		{
		var sn = document.phonesupport
		switch (toora){
				case "country":
					sn.carrier.value=""
					sn.maker.value=""
					sn.model.value=""
				break; 
					case "carrier":
					sn.maker.value=""
					sn.model.value=""				
				break; 
				case "maker":
					sn.model.value=""					
				break; 
				case "model":		
				break; 
				default : alert("This wasn\'t supposed to happen");
				}
			sn.target = "_self";
			sn.action = "phone_support.asp";
			sn.submit();
		//window.location = location.href;
		}

function processpagePro(str,str2,str3)
		{
		var sn = document.phonesupport
	
			sn.target = "_self";
			//alert(location.href)
			//sn.action = "phone_support.asp?inCountry="+str+"&inCarrier="+str2+"&inMaker="+str3+"&inModel="+str4;
			//sn.action = "/../phonesupport/"+str+"/"+str2+"/"+str3+"/"+str4;
			//sn.submit();
		    window.location = "/phonesupport/"+str+"/"+str2+"/"+str3+"/"+str4;
		}
function processpage(str,str2,str3,str4)
		{
		var sn = document.phonesupport
	
			sn.target = "_self";
			//alert(location.href)
			//window.location  = "phone_support.asp?inCountry="+str+"&inCarrier="+str2+"&inMaker="+str3+"&inModel="+str4;
			//sn.action = "/../phonesupport/"+str+"/"+str2+"/"+str3+"/"+str4;
			//sn.submit();
		    window.location = "/phonesupport/"+str+"/"+str2+"/"+str3+"/"+str4+"/";
		}
function submitthepage(){
		if(window.document.phonesupport.country.value==""){
		alert("Please Select a Country")
		return false;
		}
		else if(window.document.phonesupport.carrier.value=="" && window.document.phonesupport.country.value!=3){
		alert("Please Select a Carrier")
		return false;
		}
		else if(window.document.phonesupport.maker.value==""){
		alert("Please Select a Maker")
		return false;
		}
		else if(window.document.phonesupport.model.value==""){
		alert("Please Select a Model")
		return false;
		}
		else{
		var sn = document.phonesupport;
		sn.submit();
		}
}

function resetthepage(){
			window.location = "/phone_support_pro.asp";
		}		

function requestquery(){
/*
			var query = window.location;
			query = query.toString();
			
			if(query.indexOf('phonesupportpro')!=-1){
			
			//query = query.toString() 
			query = query.slice(query.indexOf('phonesupportpro'),query.length)
			query = query.split("/")
			var country = query[1]; 
			var carrier = query[2];
			var maker = query[3];
			//var model = query[4];
			
			query = "country="+country +"&carrier="+ carrier +"&maker="+ maker; 
			// +"&model="+ model;
			}else{
			
				query = '<%=Request.ServerVariables("HTTP_X_REWRITE_URL")%>';
			
			}
			
			//alert(query)
			
			if((query.indexOf('country')!=-1)&&(query.indexOf('model')!=-1)&&(query.indexOf('maker')!=-1)){
			     query = query.slice(query.indexOf('?')+1,query.length);
				showApexAll(query)
			}
			else{
			window.document.getElementById("carrier").innerHTML='<select name="carrier" disabled> <option value="">Please Select Carrier</option></select>'
			window.document.getElementById("maker").innerHTML='<select name="maker" disabled> <option value="">Please Select Maker</option></select>'
			window.document.getElementById("model").innerHTML='<select name="model" disabled> <option value="">Please Select Model</option></select>'
			
			}
	*/		
		}	