KrzysiekF/kkcountdown — pull request #1 by russelltodd (2013-02-27 21:08:20+00:00)
Title: Make countdown time more flexible and standards-based

I made a few tweaks to the countdown code and would like you to consider adding them to the master.

The main update was to allow a developer to specify the countdown in number of seconds rather than forcing the use of a unix timestamp. The timestamp depends on the user's browser / computer being accurate; using number of seconds allows the developer to use server-side code to countdown to a specific time reliably, regardless of the user's computer's time or timezone.

In order to allow the HTML to be validated, I switched the plugin to use HTML5 data variables, specifically "data-time" (for unix timestamps) or "data-seconds" for number of seconds.

I also added 2 options to add a "warning" class to the countdown at a certain point, so you could turn the countdown red for the last 60 seconds, for example.

Lastly, I updated the demo code.