The example of this article tells the jquery simple Countdown implementation method. Share to everyone for your reference, specific as follows:
var Intdiff = parseint (60); Total seconds count
function timer (intdiff) {
window.setinterval (function () {
var day = 0,
hour = 0,
minute = 0,
second = 0;//time default value
if (Intdiff > 0) {Day
= Math.floor (Intdiff/*));
hour = Math.floor (Intdiff/())-(day *);
minute = Math.floor (INTDIFF/60)-(Day * *)-(hour);
Second = Math.floor (Intdiff)-(* * * * (Hour *)-(minute);
if (minute <= 9) minute = ' 0 ' + minute;
if (second <= 9) Second = ' 0 ' + second;
$ (' #day_show '). HTML (day + "Days");
$ (' #hour_show '). html (' <s id= "h" ></s> ' + hour + ' time ');
$ (' #minute_show '). html (' <s></s> ' + minute + ' min ');
$ (' #second_show '). html (' <s></s> ' + second + ' seconds ');
intdiff--;
}, 1000);
$ (function () {
timer (intdiff);
});
I hope this article will help you with your jquery programming.