View Single Post
Old 01-20-2013, 12:47 AM   PM User | #1
muldaria
New to the CF scene

 
Join Date: Jan 2013
Posts: 2
Thanks: 2
Thanked 0 Times in 0 Posts
muldaria is an unknown quantity at this point
Question can i get some help with a loop?

I need to loop this timer. can i get some help with that?
Code:
<script> 
<!-- 
// 
 var milisec=0 
 var seconds=60 
 document.counter.d2.value='30' 

function display(){ 
 if (milisec<=0){ 
    milisec=9 
    seconds-=1 
 } 
 if (seconds<=-1){ 
    milisec=0 
    seconds+=1 
 } 
 else 
    milisec-=1 
    document.counter.d2.value=seconds+"."+milisec 
    setTimeout("display()",100) 
} 
display() 
--> 
</script>
muldaria is offline   Reply With Quote