[Contents]
This section list new and revised properties for:
Anchor
Link
Function
navigator
window
Client-side property. This property contains the content of the corresonding <A> tag.
<A>
linkName.text
linkName
Core property. When the LANGUAGE attribute of the SCRIPT tag is "JavaScript1.2", this property indicates the number of arguments expected by a function.
LANGUAGE
SCRIPT
"JavaScript1.2"
functionName.arity
functionName
arity
arguments.length
The following example demonstrates the use of arity.
<SCRIPT LANGUAGE="JavaScript1.2">
function addNumbers(x,y){ document.write("length = " + arguments.length + "<BR>") z = x + y }
document.write("arity = " + addNumbers.arity + "<BR>")
addNumbers(3,4,5)
</SCRIPT>
This writes:
Client-side property. Indicates the translation of the Navigator being used.
navigator.language
The language property has been added for use with the JAR Manager.
The value for language is usually a two-letter code, such as "en" and occasionally a five-character code to indicate a language sub-type, such as "zh_CN".
language
Client-side property. Indicates the machine type for which the Navigator was compiled.
navigator.platform
The platform property has been added for use with the JAR Manager.
The machine type the Navigator was compiled for may differ from the actual machine type due to version differences, emulators, or other reasons.
platform
Client-side property. Specifies the vertical dimension, in pixels, of the window's content area.
[windowReference.]innerWidth
windowReference
To create a window smaller than 100 x 100 pixels, set this property in a
Client-side property. Specifies the horizontal dimension, in pixels, of the window's content area.
top
parent
Replaced by innerHeight; height remains only for backward compatibility.
innerHeight
height
[windowReference.]height
In earlier releases, if you set this property to a number smaller than 100, JavaScript rounded it up to 100. In 4.0, it does a security check to see if the script can set the property to a number smaller than 100.
Replaced by innerWidth; width remains only for backward compatibility.
innerWidth
width
[windowReference.]width
Client-side object and a property of the window object. Represents the Navigator window's location bar.
[windowReference.]locationbar.visible
The locationbar object itself has one Boolean property, visible, that allows you to hide or show the location bar of the specified window.
locationbar
visible
The following example hides the location bar of myWindow.
myWindow
myWindow.locationbar.visible=false
Client-side object and a property of the window object. Represents the Navigator window's menu bar.
[windowReference.]menubar.visible
The menubar object itself has one Boolean property, visible, that allows you to hide or show the menu bar of the specified window.
menubar
The following example hides the menu bar of myWindow.
myWindow.menubar.visible=false
Client-side property. Specifies the vertical dimension, in pixels, of the window's outside boundary.
Client-side property. Specifies the horizontal dimension, in pixels, of the window's outside boundary.
Client-side property. Provides the current x-position, in pixels, of a window's viewed page.
windowReference.pageXOffset
The pageXOffset property provides the current x-position of a page as it relates to the upper-left corner of the window's content area. This property is useful when you need to find the current location of the scrolled page before using
pageXOffset
scrollTo
scrollBy
This is a read-only property.
The following example returns the x-position of the viewed page.
x = myWindow.pageXOffset
pageYOffset
Client-side property. Provides the current y-position, in pixels, of a window's viewed page.
windowReference.pageYOffset
The pageYOffset property provides the current y-position of a page as it relates to the upper-left corner of the window's content area. This property is useful when you need to find the current location of the scrolled page before using
The following example returns the y-position of the viewed page.
x = myWindow.pageYOffset
Client-side object and a property of the window object. Represents the Navigator window's personal bar (also called the directories bar).
[windowReference.]personalbar.visible
window object
The personalbar object itself has one Boolean property, visible, that allows you to hide or show the personal bar of the specified window.
personalbar
The following example hides the personal bar of myWindow.
myWindow.personalbar.visible=false
Client-side object and a property of the window object. Represents the Navigator window's scroll bars.
[windowReference.]scrollbars.visible
The scrollbars object itself has one Boolean property, visible, that allows you to hide or show the scroll bars of the specified window.
scrollbars
The following example hides the scroll bars of myWindow.
myWindow.scrollbars.visible=false
Client-side object and a property of the window object. Represents the Navigator window's status bar.
[windowReference.]statusbar.visible
The statusbar object itself has one Boolean property, visible, that allows you to hide or show the status bar of the specified window.
statusbar
The following example hides the status bar of myWindow.
myWindow.statusbar.visible=false
Client-side object and a property of the window object. Represents the Navigator window's tool bar.
[windowReference.]toolbar.visible
The toolbar object itself has one Boolean property, visible, that allows you to hide or show the toolbar of the specified window.
toolbar
The following example hides the tool bar of myWindow.
myWindow.toolbar.visible=false