HTML DOM Details Object

Details Object

The Details object represents an HTML <details> element.

Note: The <details> element is not supported in Internet Explorer.

Access a Details Object

You can access a <details> element by using getElementById():

Example

var x = document.getElementById(“myDetails”);

Try it Yourself »

Create a Details Object

You can create a <details> element by using the document.createElement() method:

Example

var x = document.createElement(“DETAILS”);

Try it Yourself »

Details Object Properties

Property Description
open Sets or returns whether the details should be visible (open) to the user, or not

Standard Properties and Events

The Abbreviation object supports the standard properties and events.

Post Author: Zahid Farid