[Contents]
[Previous] [Next] [Last]This section list new and revised properties for:
Anchor
and Link
objects
Function
object
navigator
object
window
object
Client-side property. This property contains the content of the corresonding <A>
tag.
linkName.text
linkName
is the name of a link or a named anchor.
Anchor
and Link
objects
Core property. When the LANGUAGE
attribute of the SCRIPT
tag
is "JavaScript1.2"
, this property indicates the number of arguments
expected by a function.
functionName.arity
functionName
is the name of a function.
Function
object
arity
is external to the function, and indicates how many arguments the function
expects. By contrast, arguments.length
provides the number of arguments
actually passed to the function.
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:
arity = 2Client-side property. Indicates the translation of the Navigator being used.
navigator.language
navigator
object
The language property has been added for use with the JAR Manager. For more information, see the
Using JAR Installation Manager for SmartUpdate.language
is a read-only property.
Client-side property. Indicates the machine type for which the Navigator was compiled.
navigator.platform
navigator
object
The platform property has been added for use with the JAR Manager. For more information, see the
Using JAR Installation Manager for SmartUpdate.Platform values are Win32, Win16, Mac68k, MacPPC and various Unix.
platform
is a read-only property.
Client-side property. Specifies the vertical dimension, in pixels, of the window's content area.
[windowReference.]innerWidth
windowReference
is either the name of a window object or one of the synonyms top
or parent.
window
object
To create a window smaller than 100 x 100 pixels, set this property in a
signed script.Client-side property. Specifies the horizontal dimension, in pixels, of the window's content area.
[windowReference.]innerWidth
windowReference
is either the name of a window object or one of the synonyms top
or parent
.
window
object
To create a window smaller than 100 x 100 pixels, set this property in a
signed script.Replaced by innerHeight
; height
remains only for backward
compatibility.
[windowReference.]height
windowReference
is either the name of a window object or one of the synonyms top
or parent
.
window
object
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.
[windowReference.]width
windowReference
is either the name of a window object or one of the synonyms top
or parent
.
window
object
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.
Client-side object and a property of the window
object. Represents the
Navigator window's location bar.
[windowReference.]locationbar.visible
windowReference
is either the name of a window object or one of the synonyms top
or parent
.
window
object
The locationbar
object itself has one Boolean property, visible
,
that allows you to hide or show the location bar of the specified window.
The following example hides the location bar of 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
windowReference
is either the name of a window object or one of the synonyms top
or parent
.
window
object
The menubar
object itself has one Boolean property, visible
,
that allows you to hide or show the menu bar of the specified window.
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.
[windowReference.]innerWidth
windowReference
is either the name of a window object or one of the synonyms top
or parent
.
window
object
To create a window smaller than 100 x 100 pixels, set this property in a
signed script.Client-side property. Specifies the horizontal dimension, in pixels, of the window's outside boundary.
[windowReference.]innerWidth
windowReference
is either the name of a window object or one of the synonyms top
or parent
.
window
object
To create a window smaller than 100 x 100 pixels, set this property in a
signed script.Client-side property. Provides the current x-position, in pixels, of a window's viewed page.
windowReference.pageXOffset
windowReference
is either the name of a window object or one of the synonyms top
or parent
.
window
object
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
scrollTo
or scrollBy
.
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
windowReference
is either the name of a window object or one of the synonyms top
or parent
.
window
object
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
scrollTo
or scrollBy
.
The following example returns the y-position of the viewed page.
x = myWindow.pageYOffset
pageXOffset
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
windowReference
is either the name of a window object or one of the synonyms top
or parent
.
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.
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
windowReference
is either the name of a window object or one of the synonyms top
or parent
.
window
object
The scrollbars
object itself has one Boolean property, visible
,
that allows you to hide or show the scroll bars of the specified window.
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
windowReference
is either the name of a window object or one of the synonyms top
or parent
.
window
object
The statusbar
object itself has one Boolean property, visible
,
that allows you to hide or show the status bar of the specified window.
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
windowReference
is either the name of a window object or one of the synonyms top
or parent
.
window
object
The toolbar
object itself has one Boolean property, visible
,
that allows you to hide or show the toolbar of the specified window.
The following example hides the tool bar of myWindow
.
myWindow.toolbar.visible=false
[Contents]
[Previous] [Next] [Last]Last Updated: 10/22/97 11:48:10
Copyright © 1997 Netscape Communications Corporation