Javascript [Electronic resources] : The Definitive Guide (4th Edition) نسخه متنی

اینجــــا یک کتابخانه دیجیتالی است

با بیش از 100000 منبع الکترونیکی رایگان به زبان فارسی ، عربی و انگلیسی

Javascript [Electronic resources] : The Definitive Guide (4th Edition) - نسخه متنی

David Flanagan

| نمايش فراداده ، افزودن یک نقد و بررسی
افزودن به کتابخانه شخصی
ارسال به دوستان
جستجو در متن کتاب
بیشتر
تنظیمات قلم

فونت

اندازه قلم

+ - پیش فرض

حالت نمایش

روز نیمروز شب
جستجو در لغت نامه
بیشتر
لیست موضوعات
توضیحات
افزودن یادداشت جدید




Availability



JavaScript 1.0


Synopsis


window.setTimeout(code, delay)

Arguments


code

A string that contains the JavaScript code to be executed after the
delay has elapsed.

delay

The amount of time, in milliseconds, before the JavaScript statements
in the string code should be executed.


Returns


An opaque value ("timeout id") that can be passed to the
clearTimeout( ) method to cancel the execution of
code.


Description



The setTimeout(
) method defers the execution of the JavaScript statements
in the string code for
delay milliseconds. Once the specified
number of milliseconds has elapsed, the statements in
code are executed normally. Note that they
are executed only once. To execute code repeatedly,
code must itself contain a call to
setTimeout( ) to register itself to be executed
again. In JavaScript 1.2, you can use Window.setInterval(
) to register code that is executed at periodic intervals.

The statements in the string code are
executed in the context of window; i.e.,
window is the current window for those
statements. If more than one statement appears in
code, the statements must be separated by
semicolons.


See Also


Window.clearTimeout( ), Window.setInterval( )


/ 844