HTML5 tag Encyclopedia

Time:2021-2-23

Labels that can be omitted

The label of the end tag is not allowed to be written: area, base, col, embed, HR, IMG, input, keygen, link, meta, param, source, track, WBR

The label of the end tag can be omitted:li、dt、dd、p、rt、optgroup、option、colgroup、thread、tbody、tr、td、th

Labels that can be completely omitted:html、head、body、colgroup、tbody

New labels

Section: a content block in a page. It can be used in chapter, page, footer or other parts of the page. It can be combined with tags such as H1, H2… To represent the document structure.

Article: refers to a piece of independent content in a page that is irrelevant to the context, such as an article.

Aside: defines content other than articles. The content of aside should be related to the content of article.

Header: the content block in the page or the title of the whole page.

Footer: a content block in a page or a footnote for the entire page.

Hgroup: a combination of content blocks in a page or the title of the entire page.

NAV: part of the navigation link.

Figure: specify independent stream content (image, chart, photo, code, etc.). The content should be related to the main content, but if it is deleted, it should not affect the document stream).

Video: video. Exp: < video SRC = “URL” controls = “controls” > Video < / video >

Audio: audio.

Embedded: used to embed content (including various media).

Mark: change color, pay attention.

Progress: progress bar. exp:<progress max=”100″ value=”85″></progress>

Time: defines the date or time, or both. This mark is for the retrieval engine, and the engine will know that this mark represents a time according to this mark. There is an attribute PubDate. When the engine reads it, it will know that the value in DataTime is the publishing time of this article, and there are two special characters T and Z in this time. T is the separator for date and time, and Z is the standard format for time. exp:<time datatime=”2016-11-21 T 10:45 Z” pubdate></time>

Datalist: defines a list of options. Use this element in conjunction with the input element to define the possible input values. exp:<input list=”cars”/><datalist id=”cars”><option value=””></datalist>

output:exp:<form oninput=”x.value=parseInt(a.value)+parseInt(b.value)”>0<input type=”range” id=”a” value=”50″>100+<input type=”number” id=”b” value=”50″>=<output name=”x” for=”a b”></output></form>

Global properties

Data type: custom attribute.

Hidden: hidden, single label.

Spellcheck: syntax correction of input content. exp:<textarea spellcheck=”true” ></textarea>

tabindex:tab Key order.

Contenteditable: modify the content. exp:<p contenteditable=”true” ></p>

Make the whole text editable: < script > window.document.designMode= “Off”; < / script > / / off off, on: editable

The above is a complete collection of HTML5 tags introduced by Xiaobian. I hope it can help you. If you have any questions, please leave me a message and Xiaobian will reply you in time. Thank you very much for your support to developer!