Example of Properties for the Window Object
This example demonstrates the properties of the window,
window.screen, window.navigator, window.location
window.history and window.document objects.
Back to DOM Properties Assignment
Internet programming 3
WebPelican Home
window properties
|
PROPERTY
|
DESCRIPTION
|
VALUE
|
|
window.name
|
Window name message
|
|
|
window.defaultStatus
|
Window default status message
|
|
|
window.status
|
Window status message
|
|
|
window.opener
|
Window opener is used to define the window who opened this window.
|
|
|
window.parent
|
Window parents message
|
|
|
window.top
|
Window top parents message
|
|
|
window.closed
|
Is window closed
|
|
window.screen properties
|
PROPERTY
|
DESCRIPTION
|
VALUE
|
|
window.screen.width
|
Screen width
|
|
|
window.screen.height
|
Screen height
|
|
|
window.screen.colorDepth
|
Screen color depth
|
|
|
window.screen.availibleWidth
|
Screen availible width
|
|
|
window.screen.availibleHeight
|
Screen availible height
|
|
window.navigator properties
|
PROPERTY
|
DESCRIPTION
|
VALUE
|
|
window.navigator.userAgent
|
Navigator userAgent is a property for all browser info
|
|
|
window.navigator.appName
|
Browser name
|
|
|
window.navigator.appCodeName
|
Browser code name
|
|
|
window.navigator.appVersion
|
Browser version
|
|
|
window.navigator.cookieEnabled
|
Does the browser allow cookies
|
|
|
window.navigator.platform
|
Computer platform.
|
|
window.location properties
|
PROPERTY
|
DESCRIPTION
|
VALUE
|
|
window.location.href
|
Browser URL
|
|
|
window.location.protocol
|
Protocol
|
|
|
window.location.hostname
|
Browser URL/hostname
|
|
|
window.location.host
|
Browser URL/host
|
|
|
window.location.port
|
Browser URL/port
|
|
|
window.location.pathname
|
Browser URL/path
|
|
|
window.location.hash
|
Browser URL/bookmark
|
|
|
window.location.search
|
Browser URL/search string
|
|
window.history properties
|
PROPERTY
|
DESCRIPTION
|
VALUE
|
|
window.history.length
|
History length
|
|
window.document properties
|
PROPERTY
|
DESCRIPTION
|
VALUE
|
|
window.document.cookie
|
document cookies
|
|
|
window.document.referrer
|
Document reference
|
|
|
window.document.domain
|
Document security domain
|
|
|
window.document.lastModified
|
When document was last modified
|
|