javascript loop after seconds site:stackoverflow.com code example
Example: js loop every x seconds
(function loop() {
setTimeout(function () {
// execute script
loop()
}, 9000); //9000 = 9000ms = 9s
}());
(function loop() {
setTimeout(function () {
// execute script
loop()
}, 9000); //9000 = 9000ms = 9s
}());