jquery - javascript setInterval clear issue -


i facing 1 issue while using setinterval method.

when jsp page loaded @ time (onload), have called 1 setinterval(function(),time) method. following onload code of jsp

var refreshloop = 0; var refreshfrequency = 900000;  $(window).load(function() {     startrefresh(); });   function startrefresh() {     refreshloop = setinterval("refreshscreen()", refreshfrequency); } 

now have drag , drop functionality on page drag 1 row div div. when drop row table table got refresh. had done ajax calling 1 drop happen div want when drop id completed want clear setinterval , make default.

ex : have set setinterval timings 10 min on page load every time load page after 10 mins . once had drag , drop start counting 10 mins once drop row div.

i had done in javascript , ajax.

please suggests on issues.

window.clearinterval(refreshloop) whenever wish clear interval.


Comments

Popular posts from this blog

java.util.scanner - How to read and add only numbers to array from a text file -

rewrite - Trouble with Wordpress multiple custom querystrings -