Simple Digital count down using Javascript | Sanwebcorner

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>
<html>
<head>
<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;
border-radius:3px;
margin:0 auto;
width: 122px;
}

#pause_btn {
background-color:#ED5565;
border:0;
border-bottom:3px solid #DA4453;
color:#fff;
border-radius:5px;
padding:10px 20px;
}

h1 { margin-bottom:30px;}
</style>
</head>
<body>

<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>
<br>
</div>
<script src="http://code.jquery.com/jquery-1.12.4.min.js"></script>
<script src="simpletimer.js"></script>
<script type="text/javascript">
$(function () {
$('.simple-timer').simpletimer({
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 () {
location.href="http://demos.sanwebcorner.com";
}
});
});
</script>
</body>
</html>

Post a Comment

Labels

360 degree view product image 3d rotate 3d text 3step-form Accordion menu ajax All Browsers Animated Background Gradient animation audio controller auto complete Best accordion menu bootstrap border bounce effect on hover Breadcrumb calculate age by dob calendar Captcha change image on mouse move color chooser countdown Counter on scroll create random number Css css animation css buttons css hover css3 customized upload Button Date picker delete data from table Different scroll speed email otp verification email verifier Embed eventlist Expanding Menu feedbck form flash news section close button full screen menu Google custom search Google Maps Google reCAPTCHA Google site search gradient hide menu Horizontal News ticker Hover Htm Html html dropdown html form html5 html5 form validation Iframe image hover increment decrement textbox value based on select box Javascript Jquery js Layered image effect on mouse hover lock & unlock page scroll marquee marquee with close button mobile number validation mobile otp login Multi-level-drop-down-menu multi-level-form multi-select-checkbox Multi-Step-form Multiple File Upload in PHP mysql News ticker on hover change text to image our team page password generator password strength checker Photoshop PHP php mailer populate html selectbox Popup image on click the link pure css Question type form random number generate Random password Redirect page Based on the select box while submit the form responsive responsive menu responsive popup box Responsive Vertical Time line design rotate image selectbox based on select box simple coming soon page simple countdown based on end date simple typing effect slider sliding tab sms otp login statistic counter on scroll switch tag shape team member Time picker toggle toggle view transparent button underline animation up down slide validation vertical fixed sidebar Webtips whatsapp link website Youtube