The Coundown Timer - by SLBushway - on WordPress WooCommerce support

This topic has 6 replies, 3 voices, and was last updated 7 years, 5 months ago ago by Jack Richardson

  • Avatar: SLBushway
    SLBushway
    Participant
    October 28, 2016 at 02:14

    Hello,

    I am using the countdown timer from the page “teaser-simple.html”, but can’t figure out how to use it. I’ve been researching it since 1pm this afternoon. I have a monthly photo contest – the next day for the best picture to be selected is Nov. 15, 2016 and a new winner will be selected on the 15th of every month. I am not a web pro and so hopefully the instructions can be dumbed down a bit.

    Thanks,
    Shawn

    5 Answers
    Avatar: Eva
    Eva Kemp
    Support staff
    October 28, 2016 at 09:23

    Hello,

    You need edit this code in the file teaser-simple.html and write your date:

    <script>
            $(function(){
                var newYear = (new Date().getFullYear())+1;
                function setTimer(){                        
                    var today = new Date();
                    var finalTime = new Date("Sep,1,"+newYear);
                    var interval = finalTime - today;
                    if(interval<0) interval = 0;
                    var days = parseInt(interval/(1000*60*60*24));
                    var daysLeft = interval%(1000*60*60*24);
                    var hours = parseInt(daysLeft/(1000*60*60));
                    var hoursLeft = daysLeft%(1000*60*60);
                    var minutes = parseInt(hoursLeft/(1000*60));
                    var minutesLeft = hoursLeft%(1000*60);
                    var seconds = parseInt(minutesLeft/(1000));
                    $('.days').text(days);
                    $('.hours').text(hours);
                    $('.minutes').text(minutes);
                    $('.seconds').text((seconds<10)?'0'+seconds:seconds);
                }
                setTimer();
                setInterval(function(){setTimer();}, 1000);
            });
        </script>

    Regards,
    Eva Kemp.

    Avatar: SLBushway
    SLBushway
    Participant
    October 28, 2016 at 18:59

    Hello,

    I know that much – I just don’t know how – I’ve entered a new starting/end date in every place I can think of and I can’t seem to get it to work. Knowing that the next contest ends on Nov. 15, 2016, how and where would you enter that information? Does it require a special format? Do I have to enter the current date? The documentation that came with the template doesn’t discuss this at all.

    Thanks,
    Shawn

    Avatar: Jack Richardson
    Jack Richardson
    Support staff
    October 29, 2016 at 09:13

    Hello,

    You need edit only two strings as shown on the screenshot http://prntscr.com/d0dac2

    Best regards,
    Jack Richardson.

    Avatar: SLBushway
    SLBushway
    Participant
    October 30, 2016 at 03:03

    Thank you :).

    Avatar: Jack Richardson
    Jack Richardson
    Support staff
    October 31, 2016 at 10:19

    Hello,

    You’re welcome.

    Best regards,
    Jack Richardson.

  • Viewing 6 results - 1 through 6 (of 6 total)

The issue related to '‘The Coundown Timer’' has been successfully resolved, and the topic is now closed for further responses

We're using our own and third-party cookies to improve your experience and our website. Keep on browsing to accept our cookie policy.