Text display in HTML

In order to displaying a text like “This is my first html page”, you should place this line between < body >…< /body > html tags.

HTML Source Code :

<html>
  <body>
    This is my first html page
  </body>
</html>

How to display HTML text as Bold ?

< b >…< /b > html tags display Bold text in html page

< b > This is HTML Bold text < /b > The above code will display the text as Bold in your html page.

How to display HTML text as Italic ?

< i >…< /i > html tags display text as Italic in html page

< i > This is HTML Italic text < /i >

The above code will display the text in italic in your html page.

How to underline HTML text ?

< u >…< /u > tags will underline HTML text

< u > This is HTML underline text < /u >

The above code put an underline the above html text.

You can use the above tags (bold, italic and underline) together in a single line.

HTML Source Code :

<html>
  <body>
    The text "HTML" will show as bold , italic and underline
    <b>HTML</b> ....<i>HTML</i> and <u>HTML</>
  </body>
</html>

You can use these three tag (bold, italic and underline) together in a same word .

HTML Source Code :

<html>
  <body>
    You can use Bold, Italic, and underline in a
    single word....<b><i><u>HTML</u></i></b>
  </body>
</html>

How to html text strikethrough ?

Sometimes you need to draw a line in the middle of the text , you can called it strikethrough or html Deleted Text.

you can use < del > … < /del > tag for displaying deleted text or strikethrough text

HTML Source Code :

<html>
  <body>
    Following text is ...  <del>deleted </del>
  </body>
</html>

How to display html content at the center of a page?

Html text is left aligned by default, if you want to display your content at the center of the page , you can use < center > .. < /center > html tag.

HTML Source Code :

<html>
  <body>
    <center>
      This line wil display at the center of the page.
    </center>
  </body>
</html>