I have a php variable

$date // unix time (int 1453884009) 

It contains the time to which you want to count

 $(function() { setTimeout(function(){ location.href=location.href }, 3600000); var dater = <?php echo (integer) $date ?>; $('#clocker').flipcountdown({ beforeDateTime: new Date(dater / 1000) }); }); 

But nothing happens, counters by zeros

  • beforeDateTime: new Date(dater / 1000) most likely multiplied by 1000 so beforeDateTime: new Date(dater * 1000) - Naumov
  • @Naumov so counters are also zeros. - donttime
  • what in variable $ date and dater in php var_dump ($ date), console.log () what do they say? - Naumov
  • @Naumov int 1453884009 here and there. It works with multiplication but outputs 16810533: 17: 31: 45 instead of 01:45 - donttime
  • And if you try just dater without division and multiplication? - Naumov

0