Javascript examples for Date Operation:Timestamp
Check date on exact time
<html> <head> <script type="text/javascript"> var startDate = new Date("2018-06-14 12:47"); window.setInterval(checkDate, 1000); function checkDate()// w w w . j a v a2 s .c o m { if (new Date() > startDate) myDate.value = new Date().toLocaleString(); //or do your alert ;) } </script> </head> <body> <input type="text" id="myDate" style="width: 200px"> </body> </html>