HTML Formatted Elements
HTML also provide each tag with predefined some styles or can say format. These format also can be change using inline style. Except the style of element some tags are included in HTML5 that have some predefined purpose of use. These element are used in semantic web. There are following tag that format text automatically. Approximately all latest browsers render these elements in the same format.
- i and em
- b and strong
HTML del tag
This tag is used to display formatted text using text-decoration strike through. This element represent deleted or removed text from the webpage content. This is very helpful for reader to know about the previous version of content.
<del> This content value vas previously used </del>
HTML ins tag
Ins stands for insertion, this tag is used to highlight newly inserted text in the content. Browser will automatically use underline format for the text of this element. This is also useful in SEO.
<ins> This is new text added from 01-03-2023 </ins>
HTML sup tag
Sup tag stands for superscript. This tag is used to display text as superscript. This element is commonly used for the presentation of formulas and functions.
HTML sub tag
Sub tag stands for subscript. Subscript element format text in such a way that text is represent relatively small to the adjacent text. This element is very useful in writing mathematical formulas.
Italic and em tag
I stands for italic tag. This tag is used to display italic text in webpage. All the text that is enclosed inside i tag will automatically display italic in all browsers. The same objective can be achieved using em tag. The difference between i and em tag is that i is non semantic tag it only italic text while em is semantic tag that not only italic text but also emphasis text. Em in HTML5 stands for emphasis, we can use it in our content for getting attention of search engines.
HTML mark tag
Mark tag has some special style to display it highlight in web browser. Normally this element highlight text using yellow color. The shade of this color may vary in different web browsers. Mark element is eye catching tag of reader.
<p> We are writing this <mark>paragraph</mark> to highlight text.</p>
We are writing this paragraph to highlight text.
HTML small tag
This tag only reduce the text size from normal text. This element will distinguish text from other paragraph text.
Bold and Strong tag
Strong and b tag both set text weight to bold. B tag is recommended where we just want bolder text, if we want to emphasis on text then we have to use strong tag.The difference between these tags is that b is non semantic while strong is semantic tag. It is recommended to use strong tag instead of b tag.