<script language="javascript" type="text/javascript">
function doChange(){
var id=document.getElementById("id").value;
if (id==null || id=="") return ;
//Create Url to connect to server
var url="getresult.php?id="+id;
var xmlhttp = new ActiveXObject("Msxml2.XMLHTTP.3.0");
xmlhttp.open('POST',url,false); //GET
xmlhttp.send();
str=xmlhttp.responseText;
document.getElementById("output").innerHTML="<b>"+ str+"</b>";
}
<script>