LEGEND | NN n/a IE 4 DOM 1 | ||
The LEGEND object reflects the LEGEND element. A LEGEND element must be nested inside and immediately after the FIELDSET element associated with a form or group of form controls. | |||
HTML Equivalent<LEGEND> | |||
Object Model Reference
|
accessKey | NN n/a IE 4 DOM n/a | ||
Read/Write | |||
A single character key that brings focus to an element or, in the
case of a LEGEND element, to the first focusable
form control in the associated FIELDSET element.
The browser and operating system determine whether the user must
press a modifier key (e.g., | |||
Exampledocument.all.myLegend.accessKey = "n" | |||
Value Single alphanumeric (and punctuation) keyboard character. | |||
|
align | NN n/a IE 4 DOM 1 | ||
Read/Write | |||
Controls the alignment of the LEGEND element with respect to the containing FIELDSET element. The permissible values do not always work as planned in Internet Explorer 4. For example, the bottom value displays the label at the top left of the fieldset rectangle. So does the top value, although it is supposed to be centered along the top. The other values (center, left, and right) work as expected, but on the Macintosh, the center and right settings inexplicably widen the fieldset rectangle. Be sure to check your desired setting on both operating system platforms. | |||
Exampledocument.all.myLegend.align = "center" | |||
Value Any one of the following constant values (as a string): bottom | center | left | right | top. | |||
|
clientHeight, clientWidth | NN n/a IE 4 DOM n/a | ||
Read/Write | |||
According to Microsoft's developer documentation, these properties reflect the height and width (in pixels) of the element's content. | |||
Examplevar midHeight = document.all.myLegend.clientHeight/2 | |||
Value Integer pixel value. | |||
|
clientLeft, clientTop | NN n/a IE 4 DOM n/a | ||
Read-only | |||
According to Microsoft's developer documentation, these properties reflect the distance between the "true" left and top edges of the document area and the edges of the element. To get or set the pixel position of an element in the document, use the pixelLeft and pixelTop properties. | |||
Value A string value for a length in a variety of units or percentage. | |||
|
scrollHeight, scrollWidth | NN n/a IE 4 DOM n/a | ||
Read-only | |||
The meaning of these two properties is ambiguous based on Microsoft's description and the way they're implemented in the Windows and Macintosh versions of Internet Explorer 4. My best guess is that these properties are intended to measure the height and width (in pixels) of the content of an element even when some of the content cannot be seen unless scrolled with scrollbars. The Macintosh version of the browser interprets this to mean the amount of the content that you can see at any one time. The important point is that for key elements, such as the BODY, the properties mean different things and can disrupt cross-platform operation. | |||
Examplevar midPoint = document.all.myLegend.scrollHeight/2 | |||
Value Positive integer or zero. | |||
|
scrollLeft, scrollTop | NN n/a IE 4 DOM n/a | ||
Read/Write | |||
The distance in pixels between the actual left or top edge of the element's physical content and the left or top edge of the visible portion of the content. Changing these properties appears to have no visual effect in Internet Explorer. | |||
Exampledocument.all.myLegend.scrollTop = 40 | |||
Value Positive integer or zero. | |||
|
blur( ) | NN n/a IE 4 DOM n/a |
Removes focus from the current element and fires an onBlur event (in IE). No other element necessarily receives focus as a result. | |
Returned Value None. | |
Parameters None. |
focus( ) | NN n/a IE 4 DOM n/a |
Gives focus to the current element and fires the onFocus event (in IE). If another element had focus at the time, it receives an onBlur event. | |
Returned Value None. | |
Parameters None. |