// JavaScript Document

 function printPage()
 {
 	str = document.getElementById("innerCont").innerHTML;
	newwin=window.open('','printwin','left=100,top=100,width=400,height=400,scrollbars=yes');
	newwin.document.write('<html xmlns="http://www.w3.org/1999/xhtml"><head>');
	newwin.document.write('<title>' + document.title + '</title>\n');
	newwin.document.write('</head>\n');
	newwin.document.write('<body>\n');
	newwin.document.write(str);
	newwin.document.write('<center><br><br><input type="button" onclick="window.close()" value="Close" name="submit">&nbsp;&nbsp;<input type="button" onclick="window.print()" value="Print" name="submit"></center></body>\n');
	newwin.document.write('</html>\n');
	newwin.location.reload(true); 
	newwin.window.print();
 }

var xmlHttp;
var url;
function showHint(str)
{
  //document.getElementById("txtHint").innerHTML="";
if (str.length==0)
  { 
  document.getElementById("txtHint").innerHTML="";
  return;
  }
xmlHttp=GetXmlHttpObject();
if (xmlHttp==null)
  {
  alert ("Browser does not support HTTP Request");
  return;
  } 
url="pageRedirect.asp";
url=url+"?locationCode=" + str;
//url=url+"&sid="+Math.random();
xmlHttp.onreadystatechange=stateChanged;
xmlHttp.open("GET",url,true);
xmlHttp.send(null);
}

function stateChanged() 
{ 
if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")
 { 
 document.getElementById("txtHint").innerHTML=xmlHttp.responseText;//"hwlo" + url;//
 } 
}

function GetXmlHttpObject()
{
var xmlHttp=null;
try
 {
 // Firefox, Opera 8.0+, Safari
 xmlHttp=new XMLHttpRequest();
 }
catch (e)
 {
 // Internet Explorer
 try
  {
  xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
  }
 catch (e)
  {
  xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
  }
 }
return xmlHttp;
}
