How do I get the current date/time in seconds in Javascript?
Date.now()
gives milliseconds since epoch. No need to use new.
new
Check out the reference here: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/now
(Not supported in IE8.)