What are the common grouping elements in HTML5
This article is about the common grouping elements of HTML5. The editor thinks it is very practical, so share it with you as a reference and follow the editor to have a look.
Commonly used grouping elements in html5: 1, p elements for paragraph grouping; 2, div elements for general grouping; 3, blockquote elements; 4, pre elements; 5, hr elements; 6, ul, ol, li elements; 7, dl, dt, dd elements; 8, figure and figcaption elements.
The operating environment of this tutorial: windows7 system, HTML5 version, Dell G3 computer.
Summary of common grouping elements in HTML5
Parsing of HTML5 grouping elements
1 、
< p >Establish a paragraph
2 、
< div >General grouping
Because div itself does not have any meaning, div is used as a final solution in the context of HTML5's strong demand for semantics.
3 、
< li >Define a list item in the list
The attributes are as follows:
Value:
This integer property indicates that this
< li >Elements are listed in an ordered list by the
< ol >The sequence number in the element definition. The value of this property can only be displayed with numbers, even if the list is displayed using Roman numerals or letters. Subsequent list entries are counted from the set value. The value property is used for unordered lists
< ul >) or menu (
< menu >) invalid.
Type:
The type of the specified number.
'a 'indicates a lowercase letter number
'A' indicates a capital letter number.
'i' indicates a lowercase Roman numeral number
'I 'means uppercase Roman numeral number
'1' represents a numeric number (the default).
Third item fourth item fifth item
Output:
III.third itemIV.fourth itemV.fifth item
< ul > < li >Define an unordered list first item second item third item
Output:
-first item-second item-third item
< ol > < li >Define an ordered list
First item second item third item
Output
-first item-second item-third item
4 、
< dl > < dt > < dd >Generate a list of instructions
< dl >Represents a collection of items.
< dt >The title of the content.
< dd >Specific content
Name Godzilla Born 1952 Birthplace Japan Color Green
Output:
Name GodzillaBorn 1952Birthplace JapanColor Green
5 、 figure 、 figcaption
Figure represents a separate piece of content, showing referenced pictures, illustrations, tables, code snippets, and so on.
Figcaption represents the illustration of the legend
An elephant at sunset
6 、 main
There can be only one main element per page, and he represents the theme of the page.
Bicycle off-road
Bicycle off-road for three generations
economic loss
Climb a naturally occurring rock face in the wild.
Thank you for reading! This is the end of this article on "what are the common grouping elements of HTML5?". I hope the above content can be of some help to you, so that you can learn more knowledge. if you think the article is good, you can share it for more people to see!