function getAllTransaction(isDriver){
    var id = sessionid;
    var xmlhttp = new XMLHttpRequest();
    xmlhttp.onreadystatechange = function () {
        if(xmlhttp.readyState == 4 && xmlhttp.status == 200){
            document.getElementById('driver-info').innerHTML = xmlhttp.responseText;
            //console.log(result.getElementById('transaction-id').innerHTML);
        }
    };
    xmlhttp.open('GET', '../controller/transactionController.php?id=' + id + '&driver=' + isDriver,true);
    xmlhttp.send();
}

function hide(id){
    xmlhttp = new XMLHttpRequest();
    xmlhttp.onreadystatechange = function () {
        if(xmlhttp.readyState == 4 && xmlhttp.status == 200){
            var elementId = 'transaction-' + id;
            document.getElementById(elementId).parentNode.parentNode.style.display = "none";
        }
    };
    xmlhttp.open('GET', '../controller/transactionController.php?id=' + id + '&hide=1',true);
    xmlhttp.send();
}