//Function is called by the form's submit button.


// FOR THIS FUNCTION, PLACE IT INSIDE THE SUBMIT BUTTON, AS AN "ONCLICK" ACTION
function choosePage(){
	
	//make sure the URL variable is empty to start with
	var url = null;
	//this will be "true" if Linux is selected.
	var win = document.form2.platformRadio[1].checked; //THIS NEEDS TO BE SET TO POINT TO THE FORM'S RADIO BTN FOR 
	//this will be "true" if ecommerce is selected
	var ecom = document.form2.ecomRadio[0].checked;//THIS NEEDS TO BE SET TO POINT TO THE FORM'S RADIO BTN
	

	//Check to see if Windows is selected (that it  holds the value "true")
	switch (win) {
	
		case true : //if it's windows, check to see if it's ecom

			if(!ecom){
				url = "windows_webhosting.html"; // YES WINDOWS, NO ECOMMERCE
			}else{
				url = "windows_ecommerce.html"; //YES WINDOWS, YES ECOMMERCE
			}
			break; // Breaks are used to tell JS to skip the rest of the switch statement
			
		default :
			//if it IS true, and linux IS selected...
			//Check to see if ecommerce is NOT selected
			if(!ecom){
				url = "linux_webhosting.html"; // YES LINUX, NO ECOMMERCE
			}else{ //otherwise, ecommerce is selected...
				//YES LINUX, YES ECOMMERCE
				url = "linux_ecommerce.html"; // YES LINUX, YES ECOMMERCE
			}
			//now that we know Linux is the platform, we dont need to check if it's Windows.
			//We can break out the switch statement because we know the platform is Linux
	}
	// Make it so...
	window.location.href = url;
	
}


function choosePage1(){
	
	//make sure the URL variable is empty to start with
	var url = null;
	//this will be "true" if Linux is selected.
	var win = 1; //THIS NEEDS TO BE SET TO TRUE TO DEFAULT TO WINDOWS AND CHOOSE BETWEEN ECOMMERCE
	//this will be "true" if ecommerce is selected
	var ecom = document.form2.ecomRadio[0].checked;//THIS NEEDS TO BE SET TO POINT TO THE FORM'S RADIO BTN


	//Check to see if Windows is selected (that it  holds the value "true")

	switch (win) {
	
		case true : //if it's windows, check to see if it's ecom

			if(!ecom){
				url = "#"; // YES WINDOWS, NO ECOMMERCE
			}else{
				url = "#"; //YES WINDOWS, YES ECOMMERCE
			}
			break; // Breaks are used to tell JS to skip the rest of the switch statement
			
		default :
			//edit the links below for coldfusion
			//if it IS true, and linux IS selected...
			//Check to see if ecommerce is NOT selected
			if(!ecom){
				url = "webhosting.html"; // NO ECOMMERCE
			}else{ //otherwise, ecommerce is selected...
				//YES LINUX, YES ECOMMERCE
				url = "ecommerce.html"; // YES ECOMMERCE
			}
			//now that we know Linux is the platform, we dont need to check if it's Windows.
			//We can break out the switch statement because we know the platform is Linux
	}
	// Make it so...
	window.location.href = url;
	
}


function choosePage2(){
	
	//make sure the URL variable is empty to start with
	var url = null;
	//this will be "true" if Linux is selected.
	var win = document.form2.platformRadio[1].checked; //THIS NEEDS TO BE SET TO POINT TO THE FORM'S RADIO BTN FOR 
	//this will be "true" if ecommerce is selected
	var ecom = 1;// THIS NEEDS TO BE SET TO TRUE TO DEFAULT TO ECOMMERCE AND CHOOSE BETWEEN PLATFORM


	//Check to see if Windows is selected (that it  holds the value "true")

	switch (win) {
	
		case true : //if it's windows, check to see if it's ecom

			if(!ecom){
				url = "windows_webhosting.html"; // YES WINDOWS, NO ECOMMERCE
			}else{
				url = "windows.html"; //YES WINDOWS, YES ECOMMERCE
			}
			break; // Breaks are used to tell JS to skip the rest of the switch statement
			
		default :
			//if it IS true, and linux IS selected...
			//Check to see if ecommerce is NOT selected
			if(!ecom){
				url = "linux_webhosting.html"; // YES LINUX, NO ECOMMERCE
			}else{ //otherwise, ecommerce is selected...
				//YES LINUX, YES ECOMMERCE
				url = "linux.html"; // YES LINUX, YES ECOMMERCE
			}
			//now that we know Linux is the platform, we dont need to check if it's Windows.
			//We can break out the switch statement because we know the platform is Linux
	}
	// Make it so...
	window.location.href = url;
	
}
