Last updated on April 21st, 2020 at 02:45 am
Reading Time: < 1 minute<!DOCTYPE html>
<html>
<body>
<button onclick="GEMCODEFunction()">Try it</button>
<button onclick="GEMCODEStopFunction()">Stop it</button>
<script>
var myGemCode;
function GEMCODEFunction() {
myVar = setTimeout(function(){ alert("GEMCODE"); }, 5000);
}
function GEMCODEStopFunction() {
clearTimeout(myGemCode);
}
</script>
</body>
</html>