Html Tutorial

HTML-Formatting

If you want to make your word bold,italic or underlined then there are options available in HTML to do that.

Let's learn how to do this?

Bold Text

To make anything bold we have to place it in between <b>..</b> tags.

Example

<body>
<p>This is a simple line.</p>
<p><b>This line is bold.</b></p> 
</body>

Output:

This is a simple line.

This line is bold.

Italic Text

To make text italic we have to place it in between <i>..</i> tags.

Example

<body>
<p>This is a simple line.</p>
<p><i>This line is italic.</i></p> 
</body>

Output:

This is a simple line.

This line is italic.

Marked Text

To highlight a text in HTML we can use <mark>..</mark> tags.

Example

<body>
<p>This is a simple line.</p>
<p><mark>This line is Marked/Higlighted.</mark></p> 
</body>

Output:

This is a simple line.

This line is italic.

Subscript Text

For showing a text as subscript we can use <sub>..</sub> tags.

Example

<body>
<p>This is a simple line.</p>This word is a <sub>subscript</sub>. 
</body>

Output:

This is a simple line.

This word is a subscript.

Superscript Text

For showing a text as superscript we use <sup>..</sup> tags.

Example

<body>
<p>This is a simple line.</p>
This word is a <sup>superscript</sup>. 
</body>

Output:

This is a simple line.

This word is a superscript.

Advertisment

Share


Advertisement