7
Hello.
I want to display the date and time on the page. For this, I started doing the small test to display a countdown:
var tempo=60;
function session(time) {
time=this.tempo;
if (this.tempo>0) {
tempo--;
document.write(tempo);
}
}
function pegaSession() {
setInterval(session, 10000);
}
session(tempo);
I haven’t treated the time yet, because I want to show decreasing, after solving this detail, I work with the parseint and parsefloat function().
Note: the correct would be
parseInt
– Silvio Andorinha
@Silvio Andorinha already corrected.
– André Nascimento