function createRequestObject()
{	var request_o; 
	var browser = navigator.appName; 
	if(browser == "Microsoft Internet Explorer")
		request_o = new ActiveXObject("Microsoft.XMLHTTP");
	else		
		request_o = new XMLHttpRequest();	
	return request_o; 
	
}
/******************** BEGIN : EXAMPLE Dont Edit ******************************************
var http = createRequestObject(); 
function getStudents()
{	http.open('get', 'ajax_test.php?action=get_student&id=' 
			+ document.frmStudent.course.value);
	http.onreadystatechange = handleStudents; 
	http.send(null);
}
function handleStudents()
{	if(http.readyState == 4)
	{	var response = http.responseText;		
		document.getElementById('student_list').innerHTML = response;
	}
}
/******************** END : EXAMPLE Dont Edit ******************************************/
var http = createRequestObject(); 
			//************************ BEGIN : StateOptions *********************************
	
function getLocation()//verify function name used in onchange event of select tag
{	
	http.open('get','php/ajax_test.php?action=getLocation&d_id='+document.frmdate.d_id.value);
	http.onreadystatechange = handlegetLocation;// it is function name,defined below 
	http.send(null);
}
function handlegetLocation()
{	
	if(http.readyState == 4)
	{	var response = http.responseText;		
		document.getElementById('show_location').innerHTML = response;//verify div tag id
	}
}		
function getHotals(loc_id)
{	
	http.open('get','php/ajax_test.php?action=getHotals&loc_id='+document.frmdate.loc_id.value);
	http.onreadystatechange = handlegetHotal;// it is function name,defined below 
	http.send(null);
}
function handlegetHotal()
{	
	if(http.readyState == 4)
	{	var response = http.responseText;		
		document.getElementById('show_Hotel').innerHTML = response;//verify div tag id
	}
}		
		
//**********************************END ***** Search [to get location select]***************************/	
		
function getLocation1()
{	
		
	http.open('get', 'php/ajax_test.php?action=getLocation1&hr_id='+ document.frmdate.hr_id.value);
	http.onreadystatechange = handlegetLocation1; 
	http.send(null);
}
function handlegetLocation1()
{	
	if(http.readyState == 4)
	{	var response = http.responseText;		
		document.getElementById('show_location1').innerHTML = response;
	}
}				
		
		
		
		


