반응형
javascript - setTimeOut
Example
Display an alert box after 3 seconds (3000 milliseconds):
setTimeout(function(){ alert("Hello"); }, 3000);
Definition and Usage
The setTimeout() method calls a function or evaluates an expression after a specified number of milliseconds.
Tip: 1000 ms = 1 second.
Tip: The function is only executed once. If you need to repeat execution, use the setInterval() method.
Tip: Use the clearTimeout() method to prevent the function to run.
반응형
'프로그래밍 > Web' 카테고리의 다른 글
[javascript] 남은 시간 카운터 - 자바스크립트 (0) | 2014.12.15 |
---|---|
대학생을 위한 웹 개발 공부용 체크리스트 (0) | 2014.12.15 |
[AngularJS] Angularjs 예제 (0) | 2014.12.10 |
[javascript] Paperclip.js: A powerful template engine for Node.js and the browser (0) | 2014.12.02 |
[JAVASCRIPT] Angular-kickstart: Develop with AngularJS faster (0) | 2014.11.19 |