TheDeveloperBlog.com

Home | Contact Us

C-Sharp | Java | Python | Swift | GO | WPF | Ruby | Scala | F# | JavaScript | SQL | PHP | Angular | HTML

HTML details tag

HTML details tag with examples, html5, forms, input, text, anchor, image, heading, marquee, textarea, paragraph, title, quotes, code etc.

<< Back to HTML

HTML Details Tag

HTML <details> tag is used to specify the additional details on the web page that the user can view or hide on demand.

According to W3C HTML specification, it is used as a disclosure widget from which user can retrieve additional information or control.

It is used together with a relevant tag known as <summary>. Technically, there is no need of summary tag, but if you ignore this then the browser will use some default text.

The <details> tag wraps all the content which you want to show or hide and the <summary> tag contains the summary and the title of the section.

HTML details is a new tag introduced in HTML5.

Let's take an example to understand this clearly.


HTML details tag attribute

HTML details tag also supports global and event attributes in HTML.

The details tag provides one specific attribute open.

AttributeDescription
openIt specifies that the details will be displayed (open) to the user.

HTML details tag example

<details>
<summary>Copyright 2011-2014.</summary>
<p> - by JavaTpoint. All Rights Reserved.</p>
<p>All content and graphics on this web site are the property of the TheDeveloperBlog.com</p>
</details>
<p><b>Note:</b> The details tag is currently only supported in Opera, Chrome, and in Safari 6.</p>
Test it Now

Output:

Copyright 2011-2014.

- by JavaTpoint. All Rights Reserved.

All content and graphics on this web site are the property of the TheDeveloperBlog.com

Note: The details tag is currently only supported in Opera, Chrome, and in Safari 6.


Supporting Browsers

Elementchrome browser Chromeie browser IEfirefox browser Firefoxopera browser Operasafari browser Safari
<details>YesNoNoYesYes
Next TopicHTML dfn Tag




Related Links:


Related Links

Adjectives Ado Ai Android Angular Antonyms Apache Articles Asp Autocad Automata Aws Azure Basic Binary Bitcoin Blockchain C Cassandra Change Coa Computer Control Cpp Create Creating C-Sharp Cyber Daa Data Dbms Deletion Devops Difference Discrete Es6 Ethical Examples Features Firebase Flutter Fs Git Go Hbase History Hive Hiveql How Html Idioms Insertion Installing Ios Java Joomla Js Kafka Kali Laravel Logical Machine Matlab Matrix Mongodb Mysql One Opencv Oracle Ordering Os Pandas Php Pig Pl Postgresql Powershell Prepositions Program Python React Ruby Scala Selecting Selenium Sentence Seo Sharepoint Software Spellings Spotting Spring Sql Sqlite Sqoop Svn Swift Synonyms Talend Testng Types Uml Unity Vbnet Verbal Webdriver What Wpf