Javascript function setInterval() with custom parameters
By Cyrille Mahieux on Tuesday, June 25 2013, 11:54 - Javascript - Permalink
Javascript method
The setInterval() method calls a function or evaluates an expression at specified intervals in milliseconds
One tricky thing is passing parameters to the function called as documentation is hard to find.
Passing Parameters to setInterval()
Make an anonymous function inside setInterval()
function load(functionParameter) { //function called by setInterval() } ... var customParameter; setInterval(function() { load(customParameter); }, 1000);
Hope this help you save time