here is a very nooby question for which answer I searched way too long while not finding anything. I'm not used to javascript but other programming languages so, how does it work if you want something to be constantly checked for?
Here my code:
var test = 0;
$( ".test_div" ).click(function() {
test = 1;
});
Now if I want to check if the variable is 1, constantly, what do I do? I tried this but it didn't work:
if (test == 1) { }
Thanks!