HTML Basic Tags

tutorial and example
tutorial and example

Heading Tags: This tag represents the document header. It is said to be a good practice if every document starts with Heading. Heading tags ranges from H1 to H6 i.e. six different levels where H1 is max size and H6 is the min size.

Example:

Try Now

Paragraph Tag: This<p> tag let your Html document text to structure into different paragraphs. This tag is a non-empty tag thus, <p> is for opening and </p> for closing tag.

Example:

Try Now

Output:

Line Break Tag: This tag is an empty tag which allows programmer to break the line immediately after its placement. Anything that follows it starts from the new line.

Example:

Try Now

Output:

Center Tag: This tag is used to put any content on the center of the page or any table cell.

Example:

Try Now

Output:


TutorialandExample.com
PRESERVE FORMATTING: As the name suggest it allows your text to follow exact format of how it is written i.e. it preserve your text on which format it is written. Syntax is <pre>….</pre>.

Example:

Try Now

Output:

Non-breaking Spaces: It is used when we don’t want browser to split the text across two lines. Its syntax is &nbsp.

Example:


Try Now

Output: