MOCKSTACKS
EN
Questions And Answers

More Tutorials









HTML Text formatting

HTML contains several elements for defining text with a special meaning.

Formatting elements were designed to display special types of text:

  • <b> - Change Text to Bold
  • <strong> - Important Text
  • <i> - Change text to italic format
  • <em> - Emphasized Text
  • <mark> - Marked text which will highlight the text.
  • <small> - Change to Smaller text
  • <del> - Change text format to Deleted.
  • <ins> - Inserted text which will be identified by browser as inserted text. usually it will appear as underline.
  • <sub> -Subscript text which will appear next to the normal text before the element.
  • <sup> - Superscript text which will appear next to the normal text before the element.

Example of text formatting

<div>
     <b>bold text</b>
     <strong>Important text</strong>
     <i>Italic text</i>
     <em>Emphasized text</em>
     <mark>Marked text</mark>
     <small>Smaller text</small>
     <del>Deleted text</del>
     <ins>Inserted text</ins>
     <sub>Subscript text</sub>
     <sup>Superscript text</sup>
</div>

Example Result

bold text

Important text

italic text

Emphasized text

Marked text

Smaller text

Deleted text

Inserted text

Subscript text : x 2 y

Superscript text : x 2

Conclusion

In this page (written and validated by ) you learned about HTML Text Formating . What's Next? If you are interested in completing HTML tutorial, your next topic will be learning about: HTML Quotation.



Incorrect info or code snippet? We take very seriously the accuracy of the information provided on our website. We also make sure to test all snippets and examples provided for each section. If you find any incorrect information, please send us an email about the issue: mockstacks@gmail.com.


Share On:


Mockstacks was launched to help beginners learn programming languages; the site is optimized with no Ads as, Ads might slow down the performance. We also don't track any personal information; we also don't collect any kind of data unless the user provided us a corrected information. Almost all examples have been tested. Tutorials, references, and examples are constantly reviewed to avoid errors, but we cannot warrant full correctness of all content. By using Mockstacks.com, you agree to have read and accepted our terms of use, cookies and privacy policy.