' Il setMinutes()metodo imposta i minuti di un oggetto data (0-59):
https://www.w3schools.com/js/tryit.asp?filename=tryjs_date_setminutes <!DOCTYPE html> <html> <body> <h2>JavaScript setMinutes()</h2> <p>The setMinutes() method sets the minutes of a date object (0-59):</p> <p id="demo"></p> <script> var d = new Date(); d.setMinutes(30); document.getElementById("demo").innerHTML = d; </script> </body> </html> ' Il setSeconds()metodo imposta i secondi di un oggetto data (0-59): https://www.w3schools.com/js/tryit.asp?filename=tryjs_date_setseconds <!DOCTYPE html> <html> <body> <h2>JavaScript setSeconds()</h2> <p>The setSeconds() method sets the seconds of a date object (0-59):</p> <p id="demo"></p> <script> var d = new Date(); d.setSeconds(30); document.getElementById("demo").innerHTML = d; </script> </body> </html> |