How to Use the details element and summary element in H5-

Source: Internet
Author: User
This article details the elements & lt; details & gt;, & lt; details & gt; as a brand new HTML5 element, which describes the details of a part of the document. Is a brand new HTML5 element that describes the details of a part of the document. Mark Tags are used together. By default . When ClickIt is displayed only after it is marked. Element. The common attributes of an element are as follows:

1) open: the value is open, which defines whether the details is visible.

2) subject: The value is sub_id, which is used to set the ID number of the project corresponding to the element.

3) draggable: The value is true or false. The function is to set whether the element can be dragged. The default value is false.

Tag essentially allows us to display and hide content when clicking a tag.

The tag contains The title of the element. In the code that combines the two, Element is The first child element of an element.

Sample Code:

              Untitled document
                 
               Page DescriptionToday is July 22, July 20, 2016
              

Effect:

Is it especially convenient? However, currently only Chrome and Safari are supported.

Label, so this effect is still implemented using js... You can try it. This code won't work in IE...

Related Articles:

How to expand and contract tags in the details of HTML5 practice every day

This section describes three HTML elements that are not commonly used:

, ,

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.