Jump to content


Check out our Community Blogs

Register and join over 40,000 other developers!


Recent Status Updates

View All Updates

Photo
- - - - -

Help with a countdown timer (for an app) using HTML script

html problem

This topic has been archived. This means that you cannot reply to this topic.
No replies to this topic

#1 Scallom

Scallom

    CC Lurker

  • Just Joined
  • Pip
  • 1 posts

Posted 20 January 2016 - 09:37 AM

Hi All,

Hope someone could help me resolve an issue I am having. I would like to create a countdown timer (or what I like to call a reverse stop watch) which count downs from say 5 minutes makes a wonderful noise and auto resets. However, I am a bit stupid with code but have some basic understanding.

The code I have at present is:

</div>
<div>
<h1>Countdown</h1>
<span id="cd_h">00</span>:
<span id="cd_m">00</span>:
<span id="cd_s">00</span>:
<span id="cd_ms">00</span>
<br/>
<br/>
<input type="button" value="Start" id="cd_start" />
<input type="button" value="Pause" id="cd_pause" />
<input type="button" value="Stop" id="cd_stop" />
<input type="button" value="Reset" id="cd_reset" />
<br/>
<br/>
<input type="text" value="300" id="cd_seconds" />
secs
<br/>
<br/>
<span id="cd_status">Idle</span>
</div>


But I have ran into a problem for starters it has the word idle at the bottom which I dont want. It also shows initially as 00:00:00 rather than 5 minutes but then just to make it worse the function buttons do not work and there is a box that says 300 seconds underneath the timer.

I have tried everything I can think of to make this work but am stuck, so hope someone can help me smile.gif

Many thanks for your time

Andrew






Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download