[Chapter 21] Reference: Window.self
Author: David Flanagan
Date: Fri Aug 29 11:21:34 1997

#

| Chapter 21 JavaScript Reference |

# Window.self Property

## Name

Window.self Property---the window itself

## Availability

Navigator 2.0, Internet Explorer 3.0

## Synopsis

    window.self

## Description

The `self` property contains a reference to the Window object specified by `window`, i.e., `window``.self` is identical to `window`. Because a reference to the current top-level window or frame is implicit in all JavaScript expressions, the `window` in the above expressions can be omitted and you can simply use `self` to refer to the current window.

## Usage

The `self` property provides a way to explicitly refer to the current window or frame when necessary (for example, when passing a the current window to a function). The `self` property is also sometimes useful for code clarity. Using `self.name` to refer to the name of the current window or frame is less ambiguous than simply using `name`, for example.

The `window` property is a synonym for the `self` property.

## See Also

"Window", "Window.window"

Window.scroll() |  | Window.setTimeout()