FORMATTING TAGS:

         HTML Provides various formatting tags which we can use to change the look and feel of the text displayed on the webpage.
1.  <b>: It is a container tag. It displays the text with bold effect
Example:
<body>
This is my First <b>HTML </b> Program
</body>

2.  <i>: It is a container tag and it displays the text with italic effect
Example:
    <body>
    This is my First <i> HTML Program </i>
    </body>

3.  <u>: It is a container tag. It displays text with underline effect.
Examples:
    <body>
    This is my First <u>HTML Program</u>
    </body>

4.  <s>: It is a container tag. It displays text with a strikeout effect
Example:
    <body>
    This is my First <s> C++ </s> HTML Program
    </body>

5.  <center>: It is a container tag. It is used to center text, images, tables, lists which is displayed on the webpages.
Examples:
<body>
<center>This is my First HTML Program</center>
</body>

6.  <font>: It is a container tag. We can change the font attributes of the text using this tag. Attributes at the font tag are:

i)  Color Attribute:
It sets the text color to the specified colored name or to the specified are RGB Hexadecimal triplet.

ii) Face Attribute:
It sets the font to the specified font name. You can specify a single font name or a list of font names. The browser will use the first font name in the list if that font name is available and if not, it will work through the rest of the list and use the first available font name.

iii)    Size Attribute:
Size attribute of the font tag sets. The font size of the text. It can take integer value between 1 and 7 size can also be set relative to the default font size size=+x where x is an integer value which will add up to the default size.
E.g. <body text=red>
    This is my first<font color=blue face=”Jokerman Candara” size=+3>HTML</font>Program
</body>
7.  <sup>: It is a container tag which is used to display super script text. In Mathmatical expression or for foot notes
e.g. <p> a<sup> 2 </sup></p>

8.  <sub>: It is a container tag. It is used to display sub-script text.
e.g. <body>
Todays date is 3<sup>rd</sup>Dec,2019 formula of water H<sub>2</sub>O
</body>

9.  <br>: It is standalone tag. It insert a line break in document.
i.e. This tag can be used when a text need to start form a new line.

10. <p>: It is a container tag and it is used to denote a paragraph. On encountering this tag the browser moves to a line and display the text.

Align Attribute:-
Align Attribute of the <p> controls the alignment at the text in the paragraph. We can set this attribute to values left [default setting], Right, Center and Justify.

11. Heading tag: If you want to emphasize contain text in a webpage then you can make use of the heading tag HTML provides 6 different level of heading <h1> to <h6>. All the heading appear in bold and the size depends on heading chosen <h1> will display the text with the highest font size and <h6> will display it with lowest font size.
E.g. <body text=red>
<h1> This is my First HTML Program </h1>
<h3> This is my First HTML Program </h3>
<h6> This is my First HTML Program </h6>
</body>

12. Del tag: Define the text that has been deleted from the document Browser display the text within these tags as strike through but implies that the content has been deleted.

Post a Comment

0 Comments