HTML Heading Tag:
HTML basically defines six levels of headings. A heading element implies all the font changes, paragraph breaks before and after, and any white space necessary to render the heading.
The heading elements are h1, h2, h3, h4, h5 & h6. h1 is on the highest (or most
important) level and h6 is at the least level.
Heading are very much important to highlight your content. <h1> headings should be used for main headings, followed by <h2> headings, then the less important <h3>, and so on till <h6>.
<h1> defines the most important heading & <h6>
defines the least important
heading:
<h1>This is heading 1</h1>
<h2>This is heading 2</h2>
<h3>This is heading 3</h3>
<h4>This is heading 4</h4>
<h5>This is heading 5</h5>
<h6>This is heading 6</h6>
HTML Paragraph Tag:
The <p> element or the paragraph element represents a paragraph. A paragraph always starts on a new line, and browsers automatically add some white space (a margin) before and after a paragraph.
Paragraphs are usually represented in visual media as blocks of text separated from adjacent blocks by blank lines and/or first-line indentation, but HTML paragraphs can be any structural grouping of related content, such as images or form fields.
Dont forget to end the </p> tag. Although it is not mandatory to do so, but it is a
good practise to end the paragraph tag.
HTML paragraphs are defined with the <p>
tag:
<p>This is a paragraph.</p>
<p>This is another paragraph.</p>
Conclusion:
A heading element implies all the font changes, paragraph breaks before and after, and any white space necessary to render the heading whereas The HTML <p> element defines a paragraph, it always starts on a new line, and browsers automatically add some white space before and after a paragraph.
Happy Learning !
No comments:
Post a Comment
Comments