<!DOCTYPE html>
<html>
<head>
<title>il metodo getSeconds() in JavaScript</title>
<script type="text/javascript">
var oggi = new Date();
var secondiOggi = oggi.getSeconds();
document.write("<p>I secondi dell'orario in questo momento sono " + secondiOggi + "</p>");
var timestamp = new Date(390655800000);
var secondiTimestamp = timestamp.getSeconds();
document.write("<p>I secondi dell'orario corrispondente a questo timestamp in millisecondi sono " + secondiTimestamp + "</p>");
</script>
</head>
<body>
</body>
</html>