HTML Tags Part I

What are HTML Basic Tags, Meta Tags and Programming Tags?

As we already discussed about HTML Tags earlier. Now we are going to discuss each of Tags step by step in details with practical.

Here you can check the format of HTML code which looks likes: 

Format of Code:

<!DOCUMENT HTML>
<html>
<head>
<title></title>
</head>
<body>
----rest document code----
</body>
</html>

In this HTML Tags Part I we are going to discuss about few basics but very important HTML tags. Without these tags it’s not possible to design and run a Web Page. So let’s start.

In this post we will describe 3 types of HTML tags:

  • HTML Basic Tags
  • HTML Meta Tags
  • HTML Programming Tags


HTML BASIC TAGS

Tag

Tag Name

Description

<!DOCTYPE>

Document Type

Define the type of document

<html>

HTML Main

Define the HTML page

<body>

HTML Page Body

Define the content of the page

<h1> to <h6>

Heading

Heading style 1 to 6

<p>

Paragraph

Paragraph

<br>

Break Row

Row to Next line

<hr>

Horizontal Row

Make a line

<!--..-->

Comments

Comment any content.


Important Notes and Tips:
  • The basic tags are necessary for start with new HTML document.
  • For formatting, earlier we were using inline text formatting, which comes under your tags but now we are using CSS to design our page more attractive. CSS we will study after completing HTML course.

Lets Checkout this example:

Code:

Result:

Explanation of code:

You can check below explanation for above code and result.


HTML Meta Tags

The metadata will not be displayed on the page, but will be machine parable. The <meta> tag provides metadata about the HTML document. Its elements are typically used to specify page description, keywords, author of the document, last modified and other metadata.

Tag

Tag Name

Description

<head>

Head Tag

Head tag define information about the document.

<meta>

Meta Info Tag

Meta info defines metadata about the document.

<base>

Base URL tag

Base tag specifies the base URL/Target for all relative URLs in a document.


Important Notes and Tips:

  • The <head> element is a container for metadata (data about data) and is placed between the <html> tag and the <body> tag.
  • The following tags can go inside the <head> element:
    • <title> Require for every html page.
    • <style>
    • <base>
    • <link>
    • <meta>
    • <script>
    • <noscript>
  • The title of your document under “<title> Title tag” can be big but not more than 50 lines, it will help you to grab your page to search engine like Google. 
  • <meta> tags always go inside the <head> element, and are typically used to specify character set, page description, keywords, author of the document, and viewport settings.
  • There can only be one single <base> element in a document, and it must be inside the <head> element.
Code:

Result:

Code Explain: