var xmlHttp2;

function getpage_book(hotelid)
{
xmlHttp2=GetXmlHttpObject();

if (xmlHttp2==null)
{
alert ("Browser does not support HTTP Request");
return;
}

var url="/new09/inc/book/book-active-include.php";
url=url+"?hotelid="+hotelid;
url=url+"&checkin="+document.getElementById('checkin').value;
url=url+"&nights="+document.getElementById('nights').value;
url=url+"&rooms="+document.getElementById('rooms').value;
url=url+"&noguests="+document.getElementById('noguests').value;
document.getElementById("booking_form_div").innerHTML='<h1 class="hotel">Gathering Data</h1><img style="margin:20px 260px;" src="/new09/images/loading.gif" alt="Loading Images" />';
xmlHttp2.onreadystatechange=stateChanged_book;
xmlHttp2.open("GET",url,true);
xmlHttp2.send(null);
}


function stateChanged_book()
{
if (xmlHttp2.readyState==4 || xmlHttp2.readyState=="complete")
{
document.getElementById("booking_form_div").innerHTML=xmlHttp2.responseText;
}
}

function GetXmlHttpObject()
{
var xmlHttp2=null;

try
{
// Firefox, Opera 8.0+, Safari
xmlHttp2=new XMLHttpRequest();

}
catch (e)
{
//Internet Explorer
try
{
xmlHttp2=new ActiveXObject("Msxml2.XMLHTTP");

}
catch (e)
{
xmlHttp2=new ActiveXObject("Microsoft.XMLHTTP");

}
}
return xmlHttp2;

}
