<html> <body> <button onclick="var myDate = new Date(); alert(myDate.valueOf());">valueOf</button> </body> </html>