function getXmlHttp(){
  var xmlhttp;
  try {
    xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
  } catch (e) {
    try {
      xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
    } catch (E) {
      xmlhttp = false;
    }
  }
  if (!xmlhttp && typeof XMLHttpRequest!='undefined') {
    xmlhttp = new XMLHttpRequest();
  }
  return xmlhttp;
}

function vote() {
    var req = getXmlHttp()
    for (i=0;i<document.vot.bal.length;i++)
     {
       if (document.vot.bal[i].checked)
        {
          ball=document.vot.bal[i].value;
        }
     }
    var blid=document.vot.id.value;
    req.open('GET', './vote.php?point='+ball+'&id='+blid, true); 
    req.onreadystatechange = function() {
        if (req.readyState == 4) {
            if(req.status == 200) {
               alert(req.responseText);
            }
        }
    }
  
    req.send(null); 
}