HTML open Attribute: This attribute can be defined as a boolean attribute. It specifies that the details should be visible by default. If it is not present by default than details are not shown…
HTML open Attribute
This attribute can be applied to the <details> element.
Syntax: <details open> content… </details>
Browser Support
This attribute is supported by the following browsers:
- Chrome-12.0
- Firefox-does not support
- Internet Explorer-does not support
- Safari-6.0
- Opera-15.0
Example: for <details> element
<!DOCTYPE html> <html> <body> <details open> <summary>Copyright 1999-2018.</summary> <p> - by Refsnes Data. All Rights Reserved.</p> <p>All content and graphics on this web site are the property of the company Refsnes Data.</p> </details> </body> </html>
Output:
Copyright 1999-2018.
– by Refsnes Data. All Rights Reserved.
All content and graphics on this web site are the property of the company Refsnes Data.
This example demonstrates a details list which is open by default.
Note: The details tag is not supported in Internet Explorer.