If you obtain a handle, either method can have its triggering ceased
the set time out has been given a function to call in 10 seconds but the very next line clears the timer because a handle was obtained that can then be used to clear the timer. The same procedure for setInterval is employed if you want some control over how many callbacks take place.
That will call the someFunc() function 10 times before clearing the call back.
c = c + 1;
console.log(">>> c="+c); // output to the browsers console
Please remember to wrap any code you have in forum tags:-
[CODE]...[/CODE] [HTML]...[/HTML] [PHP]...[/PHP]
If you can't think outside the box, you will be trapped forever with no escape...