C
C
CrewCut2015-10-17 20:47:04
JavaScript
CrewCut, 2015-10-17 20:47:04

How to implement a function repeat every second in jQuery?

It is necessary to perform a certain check by the function every second, regardless of the user's behavior or his presence on the tab. Tell me how to implement this, I couldn’t google, apparently I don’t know how to correctly formulate

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
Magzhan Birgebayuly, 2015-10-17
@CrewCut

Why use jQuery when there is JavaScript?

setInterval(function(){
  /* тело функции */
}, 1000); // 1000 м.сек

It will work even if you minimize the browser.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question