setUTCSeconds() 예제
<button onclick="homzzang()">클릭</button> <p id="demo"></p> <script> function homzzang() { var d = new Date(); d.setUTCSeconds(30); document.getElementById("demo").innerHTML = d; } </script> 결과보기
<button onclick="homzzang()">클릭</button>
<p id="demo"></p>
<script>
function homzzang() {
var d = new Date();
d.setUTCSeconds(30);
document.getElementById("demo").innerHTML = d;
}
</script>
결과보기
결과값: Thu Aug 01 2019 13:08:30 GMT+0900 (한국 표준시)