Refresh page at fixed intervals

Topics related to client-side programming language.
Post questions and answers about JavaScript, Ajax, or jQuery codes and scripts.
Posts: 48

Refresh page at fixed intervals

How can I refresh the page after a specified time?
I have a html table with data from server. These data are changed to every 3 minutes, so I want to refresh the page after 3 minutes.

You can use the reload() function added in setTimeout().

Code: Select all

// refresh page after 3 min. (true to load from server, not from cache)
setTimeout(function(){location.reload(true); }, 3000*60);

Similar Topics