avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • November 16, 2018, 06:23 AM
  • Proudly celebrating 13 years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Author Topic: Coding Snack Request: Javascript countdown timer with multiple weekly targets  (Read 3418 times)


  • First Author
  • Administrator
  • Joined in 2005
  • *****
  • Posts: 38,960
    • View Profile
    • Mouser's Software Zone on
    • Read more about this member.
    • Donate to Member
I had an idea for my favorite web comic, Head in the Clouds, created by dc members Tim and Nick (and now done by Tim).

The idea was a javascript/php countdown that shows how long until the next comic will be posted.

There are lots of countdown timers available; but i've not found one that let the author easily set multiple weekly target times.

So i was thinking some javascript that could be invoked using something like this:

in html file:
Next comic will be posted in
EmbedCountdownTimer("monday 18:00 cst; wednesday 18:00 cst");

That would produce a live timer that said something like "Next comic will be posted in 2 days, 6 hours, 10 minutes"

note: maybe it would be better to use cron format to specify the target times?