LayerArray object (Object/Navigator)

An array containing a list of layers in the document.


JavaScript - 1.2
Netscape - 4.0
JavaScript syntax:NmyLayerArray = myDocument.layers
Object properties:length

Each item in this array corresponds to a <LAYER> tag in the document. This array also includes layers that are created in Netscape by setting the position attribute of an HTML <DIV> tag to absolute.

The layers in this array are ordered according to the order in which they appear in the document. Layers can be accessed associatively if they have been given an ID with the ID="..." or NAME="..." tag attribute. This means you can refer to an element whose ID is set to ABC by its unique name, either as document.ABC or document.layers["ABC"].


See also:Collection object, DIV object, Document.layers[], Layer object, Layer.layers[]

length1.2 1.2 n/a4.0 4.0 n/a n/a n/a n/a n/a n/a n/aWarning , ReadOnly, Deprecated