var xmlhttp;

function processPayment(oForm)
{
	xmlhttp=null;
	// code for Mozilla, etc.
	if (window.XMLHttpRequest){
		xmlhttp=new XMLHttpRequest();
	}
	// code for IE
	else if (window.ActiveXObject){
		xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
	}
	
	alert(oForm.sCCN.value);
	
	if (xmlhttp!=null){

		//alert(TargetRequest);
		//xmlhttp.onreadystatechange=paymentResponse;
		//xmlhttp.open("GET",TargetRequest,true);			
		//xmlhttp.send(null);							

	}
	else{
		alert("An error ocurred while trying to unlink you from your roommates group.\nPlease try to unlink yourself by using the \"roommates\" link on your navigation bar.");
	}

}

function paymentResponse(){
	// if xmlhttp shows "loaded"
	if (xmlhttp.readyState==4){
		// if "OK"
		//alert(xmlhttp.status);
		if (xmlhttp.status==200){
			alert("Payment API Responded");
			
		}else{
			alert("An error ocurred while trying to unlink you or your roommates.\nYou may need to unlink yourself manually from the group.");
			
		}
	}
}
	