Warrior Forum - The #1 Digital Marketing Forum & Marketplace

Warrior Forum - The #1 Digital Marketing Forum & Marketplace (https://www.warriorforum.com/)
-   Programming (https://www.warriorforum.com/programming/)
-   -   How to set date for countdown timer? (https://www.warriorforum.com/programming/1113978-how-set-date-countdown-timer.html)

GowebMkt 22nd September 2015 03:09 PM

How to set date for countdown timer?
 
Hi Warriors,

I am using this countdown timer script...seen here:

https://github.com/sonnyt/downCount

I have put the date / time info on the custom.css file...no go.

Its being used on this site:
Top Jimmy Construction - Web Site Coming Soon!

Thanks in advance for help on this!

Bret

wordpress+expert 22nd September 2015 11:17 PM

Re: How to set date for countdown timer?
 
Hi. You need to insert code in html file. Sample code:

Code:

   
<script class="source" type="text/javascript">
        $('.countdown').downCount({
            date: '24/09/2014 12:00:00',
            offset: +10
        });
    </script>

Or insert code in custom js file. Sample code:


Code:

   
(function ($) {
        $('.countdown').downCount({
            date: '24/09/2014 12:00:00',
            offset: +10
        });
})(jQuery);


GowebMkt 23rd September 2015 07:30 AM

Re: How to set date for countdown timer?
 
I already have this code in custom.js


$(function() {
window.scrollReveal = new scrollReveal();
"use strict";

// PreLoader
$(window).load(function() {
$(".loader").fadeOut(400);
});

// Backstretchs
$("#header").backstretch("images/3.jpg");
$("#services").backstretch("images/3.jpg");

// Countdown
$('.countdown').downCount({
date: '12/12/2015 12:00:00',
offset: +10
});

});

wordpress+expert 23rd September 2015 07:56 AM

Re: How to set date for countdown timer?
 
1 Attachment(s)
Replace these files:

GowebMkt 23rd September 2015 08:59 AM

Re: How to set date for countdown timer?
 
Hey - that worked - thanks!

I see the 'custom.js' file is the same as the orig....can you please tell me what you did diff on the jquery.downCount.js file?

Thanks again!!

wordpress+expert 23rd September 2015 10:08 AM

Re: How to set date for countdown timer?
 
You're welcome.

In file jquery.downCount.jz I replaced the line 10 on:

Code:

date: null,


All times are GMT -6. The time now is 03:34 PM.