Coding With Fun
Home Docker Django Node.js Articles Python pip guide FAQ Policy

HTML5 <sub> with <sup> tag


May 03, 2021 HTML5


Table of contents


HTML5 and sup, respectively, define sub-labels and super-labels for content in the document. Please refer to the following example:

Underseed text:

<p>这个文本包含 <sub>下标</sub>文本。</p>
Try it out . . .

Browser support

HTML5 <sub> with <sup> tag HTML5 <sub> with <sup> tag HTML5 <sub> with <sup> tag HTML5 <sub> with <sup> tag HTML5 <sub> with <sup> tag

All major browsers support the hashtag.

Definitions and usages

The label defines the subseeding text. The upper text can be defined.

The difference between HTML 4.01 and HTML 5

No.

Example

这段文本包含 <sub>下标</sub>
      
这段文本包含 <sup>上标</sup>

Property

The standard property

class, contenteditable, contextmenu, dir, draggable, id, irrelevant, 
lang, ref, registrationmark, tabindex, template, title

For a complete description, visit standard properties in HTML 5.

The event property

onabort, onbeforeunload, onblur, onchange, onclick, oncontextmenu, 
ondblclick, ondrag, ondragend, ondragenter, ondragleave, ondragover, 
ondragstart, ondrop, onerror, onfocus, onkeydown, onkeypress, onkeyup, 
onload, onmessage, onmousedown, onmousemove, onmouseover, onmouseout, 
onmouseup, onmousewheel, onresize, onscroll, onselect, onsubmit, onunload

For a complete description, visit event properties in HTML 5.

Labels are useful when adding footnotes to documents and representing exponential values in equations!