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

#

| Chapter 21 JavaScript Reference |

# Window.window Property

## Name

Window.window Property---the window itself

## Availability

Navigator 2.0, Internet Explorer 3.0

## Synopsis

    window.window

## Description

The `window` property is identical to the `self` property; it contains a reference to the Window object specified by `window`. That is, `window``.window` is identical to `window` itself. 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 `window` to refer to the current window.

## Usage

The `window` property (and its synonym, `self)` provides a way to explicitly refer to the current window or frame when necessary, or when convenient for code clarity. To open a new window in an event handler, for example, it is necessary to use `window.open()`, because `open()` by itself would be confused with the `Document.open()` method.

## See Also

"Window", "Window.self"

Window.top |  | JavaScript Resources on the Internet