HTML Tags Heading, Italic and Code
The Header
The HTML headings are of six types “h1” to “h6”. All the HTML headings are in bold. You can have a feel of the headings by the example below.
Code
<h1>HTML heading h1 </h1>
<h2>HTML heading h2 </h2>
<h3>HTML heading h3 </h3>
<h4>HTML heading h4 </h4>
<h5>HTML heading h5 </h5>
<h6>HTML heading h6 </h6>
Output
HTML heading h1
HTML heading h2
HTML heading h3
HTML heading h4
HTML heading h5
HTML heading h6
The Italic <i> .. </i> Element
The content of Italic element are italicised when displayed by the browser. The example given below will clarify this.
Code
No Italics <i>This text is italicised.</i>
Output
No Italics This text is italicised.
The HTML Code <code>..</code> Element
The HTML Code tag was meant to give a feel of codes as written in different code-editors. So, all the text content directly inside this element is monospaced.
All the codes on this website have been put inside the <code> element only.
Code
<code>This text will appear as codes.</code>
Output
This text will appear as codes.
Now a days CSS is used to set the font family. (CSS property font-family:monospace)
Now one important element .. is left. We will learn this element after learning the HTML attributes.
- 354 reads
