document.classes.display

JavaScript 1.2+ Nav4+ Syntax

document.classes.className.tagName.display

Description

The display property specifies an element is displayed when associated with the class called className. The definition can also specify a tag or the word all for tagName.

The display property can be assigned one of the following values: inline, block, list-item, or none.

Specifying an inline value is equivalent to using the <em> tag. The block value is the same as creating header text with the <h> tag. Using list-item is equivalent to using the <li> tag. If none is specified, the element is not displayed.

Example

Listing 7.72 sets the display property equal to "block" to create header text. Block consists of a line break ...

Get Pure JavaScript now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.