Friday 5 August 2022

HTML Phrase tag

 HTML Phrase tag

Abbreviation tag : <abbr>

  1. <p>An <abbr title = "Hypertext Markup language">HTML </abbr>language is used to create web pages. </p>  

Acronym tag: <acronym> (not supported in HTML5)

Marked tag: <mark>

The content written between <mark> and </mark> tag will show as yellow mark on browser. This tag is used to highlight a particular text.

Strong tag: <strong>

Emphasized tag : <em>

Definition tag: <dfn>

When you use the <dfn> and </dfn> tags, it allow to specify the keyword of the content. 

  1. <p><dfn>HTML </dfn> is a markup language. </p>  

Quoting tag: <blockquote>

The HTML <blockquote> element shows that the enclosed content is quoted from another source. The Source URL can be given using the cite attribute, and text representation of source can display using <cite> ..... </cite>element.

  1. <blockquote cite=""><p>?The first step toward success is taken when you refuse to be a captive of the environment in which you first find yourself.?</p></blockquote>   
  2.  <cite>-Mark Caine</cite>

Short quote tag : <q>

An HTML <q> ....... </q> element defines a short quotation. If you will put any content between <q> ....... </q>, then it will enclose the text in double quotes.

Code tag: <code>

The HTML <code> </code> element is used to display the part of computer code. It will display the content in monospaced font.

  1. <p>First Java program</p>  
  2.       <p><code>class Simple{ public static void main(String args[]){   
  3.        System.out.println("Hello Java"); }} </code>  
  4.      </p>  

Keyboard tag: <kbd>

In HTML the keyboard tag, <kbd>, indicates that a section of content is a user input from keyboard.

  1. <p>Please press <kbd>Ctrl</kbd> + <kbd>Shift</kbd> + t<kbd></kbd> to restore page on chrome.</p>  

Address tag: <address>

An HTML <address> tag defines the contact information about the author of the content. The content written between <address> and </address> tag, then it will be displayed in italic font.

HTML Formatting Tags


HTML Formatting Tags

1. Bold

2. Strong

3. Italic

4. Emphasis

5. Mark - If you want to mark or highlight a text

5. Underline

6. Strike

7. del

8. insert

9. Superscript

10. Subscript

11. Big

12. Small

13. Monospaced Font

If you want that each letter has the same width then you should write the content within <tt>.............</tt> element.

Note: We know that most of the fonts are known as variable-width fonts because different letters have different width. (for example: 'w' is wider than 'i'). Monospaced Font provides similar space among every letter.