Skip to content

Instantly share code, notes, and snippets.

@tcarlsen
Last active August 29, 2015 14:15
Show Gist options
  • Save tcarlsen/39506c6fd84f42c25d61 to your computer and use it in GitHub Desktop.
Save tcarlsen/39506c6fd84f42c25d61 to your computer and use it in GitHub Desktop.
<link rel="stylesheet" href="/path/to/flipclock.css">
<style>
.cd-container {
display: inline-block;
}
</style>
<div class="cd-container">
<div class="countdown"></div>
</div>
<script src="/path/to/flipclock.min.js"></script>
<script>
var currentDate = new Date();
var coutdownToDate = new Date('YYYY-MM-DD HH:MM:SS');
var diff = coutdownToDate.getTime() / 1000 - currentDate.getTime() / 1000;
$('.countdown').FlipClock(diff, {
autoStart: true,
countdown: true,
showSeconds: false,
clockFace: 'DailyCounter',
language: 'danish'
});
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment