Simple Digital count down using Javascript

This is one of the simple way to create the digital countdown using jquery and javascript. This is very useful when you set the countdown for page redirect or to set time to launch some product in your website. In this example have the simple digital countdown and after coundown completed it will redirect to the particular url. Below is the demo and full code you can use it. I hope this will useful.

Simple Digital count down using Javascript

<!doctype html>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Simple Digital count down set redirect url after countdown using javascript </title>
<style type="text/css">
* {
padding: 0;
margin: 0;
body { font-family:'Roboto'; background-color:#f7f7f7;}
.container { margin:150px auto; max-width:70%;}
.simple-timer {
height: 20px;
line-height: 20px;
/*box-sizing: border-box;*/
padding: 20px;
display: block;
background-color: #000000;
color: #FFD400;
margin:0 auto;
width: 122px;

#pause_btn {
border-bottom:3px solid #DA4453;
padding:10px 20px;

h1 { margin-bottom:30px;}

<div class="container">
<h1 style="text-align:center;">How to Create Simple Digital count down set redirect url after countdown using Javascript</h1>
<div class="simple-timer"> <span class="timer-day">00</span>
<label class="separator">:</label>
<span class="timer-hour">00</span>
<label class="separator">:</label>
<span class="timer-minute">00</span>
<label class="separator">:</label>
<span class="timer-second">00</span> <span class="timer-millisecond">0</span> </div><br>
<script src=""></script>
<script src="simpletimer.js"></script>
<script type="text/javascript">
$(function () {
day: 0,
dayDom: '.timer-day',
hour: 0,
hourDom: '.timer-hour',
minute: 1,
minuteDom: '.timer-minute',
second: 5,
secondDom: '.timer-second',
millisecond: 0,
millisecondDom: '.timer-millisecond',
blank: 100,
endFun: function () {

Post a Comment