var myVar;
var totalCount=0;
accCounter=0;
document.getElementById('BUTTON').onclick = function() { buttonClicked(); totalCount+=1; console.log("total",totalCount); }
function myFunction() { myVar= window.setInterval(120000); }
function buttonClicked() { if (totalCount + accCounter> 9) { document.getElementById("BUTTON").disabled = true; } }