The Window object is the top level object in the
JavaScript hierarchy.
Window Object Collections
frames[] Returns all named frames in the window
Closed Returns whether or not a window has been closed
defaultStatus Sets or returns the default text in the
statusbar of the window
Document See Document object
history
Length Sets or returns the number of frames in the window
Location
Name Sets or returns the name of the window
Opener Returns a reference to the window that created the
window
outerHeight Sets or returns the outer height of a window
outerWidth Sets or returns the outer width of a window
pageXOffset Sets or returns the X position of the current
page in relation to the upper left corner
pageYOffset Sets or returns the Y position of the current
page in relation to the upper left corner
Parent Returns the parent window
Personalbar Sets whether or not the browser's personal
bar (or directories bar) should be visible
Scrollbars Sets whether or not the scrollbars should be
visible
Self Returns a reference to the current window
Status Sets the text in the statusbar of a window
Statusbar Sets whether or not the browser's statusbar
should be visible
Toolbar Sets whether or not the browser's tool bar is
visible or not
Top Returns the topmost ancestor window
Window Object Methods
alert() Displays an alert box with a message and an OK
button
blur() Removes focus from the current window
clearInterval() Cancels a timeout set with setInterval()
clearTimeout() Cancels a timeout set with setTimeout()
close() Closes the current window
confirm() Displays a dialog box with a message and an OK
and a Cancel button
createPopup() Creates a pop-up window
focus() Sets focus to the current window
moveBy() Moves a window relative to its current position
moveTo() Moves a window to the specified position
open() Opens a new browser window
print() Prints the contents of the current window
prompt() Displays a dialog box that prompts the user for
input
resizeBy() Resizes a window by the specified pixels
resizeTo() Resizes a window to the specified width and
height
scrollBy() Scrolls the content by the specified number of
pixels
scrollTo() Scrolls the content to the specified
coordinates
setInterval() Evaluates an expression at specified
intervals
setTimeout() Evaluates an expression after a specified
number of milliseconds
No comments:
Post a Comment