2

I am using keith Wood jquery countdown plugin for my coming soon page and i want to add 7 days 10 hours 40 minutes countdown. You can find more here http://keith-wood.name/countdown.html

This is my code:

function countdown () {

    // src: http://keith-wood.name/countdown.html
    layout = $('.timer').html();
    var newYear = new Date(); 
    newYear = new Date(newYear.getDate() + 7, 1 - 1, 1); 
    $('.timer').countdown({until: newYear, layout: layout}); 

}

Thanks in advance!

Waseem Barcha
  • 197
  • 1
  • 4
  • 14

1 Answers1

0

Use this code:

function countdown () {

    layout = $('.timer').html();
    date =  new Date("2016-05-20T13:00:00");
    var d = new Date(0);
    d.setUTCSeconds(date);
    $('.timer').countdown({until: date, layout: layout}); 


}
Ilyas karim
  • 4,592
  • 4
  • 33
  • 47