// JavaScript Document
function getXmlHttpObject() {
	var XmlHttp = false;
	try {
	 XmlHttp = new ActiveXObject("Msxml2.XMLHTTP");
	 }catch(e){
		try{
			XmlHttp = new ActiveXObject("Microsoft.XMLHTTP");
		}catch(E){
			XmlHttp = new XMLHttpRequest();
		}
	}
	return XmlHttp;
}
function makeRequest(type, page, divID, sendF, message) {
	//alert('we made it');
	var objXmlHttp = getXmlHttpObject();
	var objDiv = document.getElementById(divID);
	objDiv.innerHTML = message;
	objXmlHttp.open(type, page, true);
	//alert('we made it');
	objXmlHttp.setRequestHeader("Content-Type", "application/x-www-form-urlencoded; charset=UTF-8");
	objXmlHttp.onreadystatechange = function() {
		if (objXmlHttp.readyState == 4 && objXmlHttp.status == 200) {
			//alert(objXmlHttp.responseText);
			objDiv.innerHTML = objXmlHttp.responseText;
		}
	}
		
	if (sendF) {
		//alert(sendF);
		objXmlHttp.send(sendF);
	}
	else
	{
		objXmlHttp.send(null);	
	}
}
function submitForm(){
		document.frmEmail.submit();
		document.getElementById('formArea').innerHTML = '<div align=\'center\'><img src=\'http://www.e-rockford.com/img/ajax-loader.gif\' /><br/>Sending...Please wait</div>';
		hideStatus();
	}
function hideStatus(){
	document.getElementById('formArea').innerHTML = 'Your video link has been sent!';	
}
