Define the Distinguish among Tags, Elements, and Attributes in HTML

In Web Designing Skills, Webmaster Skills
The Distinguish of Tags, Elements, and Attributes

Previously, we have discussed the introduction to HTML and also Text Editor for Programming. Now we are going to learn the basic HTML skills of using Tags, Elements, and Attributes in HTML. These three basic HTML skills are the fundamental of HTML coding, or the basis of the whole web pages view that exist on the internet.


Tags in HTML are the codes that are used to tell a web browser about what an HTML text is written for. HTML requires a way to introduce the written text in it to the web browser. HTML tags could be telling a web browser whether the text is a list, a text and paragraph formats in HTML, link, or whatsoever.

So, that’s the use of HTML tags. In HTML tag writing, almost all of the code use an opening and closing tag, in which the primary object is in between the opening and closing tags. The following is how to explain how to use the opening and closing tag in HTML.

<tag>the object</tag>

The difference between opening and closing tags is the marker. An opening HTML tag begins with a “less-than bracket” symbol and ends with a “greater-than bracket” symbol (<>), while in the closing HTML tag begins with an “less-than bracket” symbol, then, followed by a backslash, and ends with a “greater-than bracket” symbol (</>).

The following is the list of types of HTML tags that you will often use in web coding:

1.<a>To define an anchor to interconnect between
one HTML document to another HTML document (Create a link).
2.<b>To bolt the text.
3.<p>To make a paragraph.
4.<h1>To make a top-level heading (Heading 1)
5.<h2>To make a sub-heading or heading level 2 (Heading 2)
6.<h3>To make a sub-heading or heading level 3 (Heading 3)
7.<body>To define the body or the main content of an HTML document.
8.<head>To define the head section of an HTML document.
9.<title>To define the title of an HTML document.
10.<div>To define a paging.
11.<link>To define the relationship between two documents.
12.<script>To define a client-side script.
13.<table>To define a table.
14.<th>To define the header section of a table.
15.<td>To define a cell in a table.
16.<tr>To define a row inside a table
17.<ul>To define a set of a list in a bullet format.
18.<li>To define a list.

HTML Elements

The elements of HTML are the content or objects between the tags. In other words, the elements of HTML are the primary objects between the opening and the closing tags e.g.:

<!DOCTYPE html>
<strong><h2>Introduction to HTML attribute</h2></strong>

The example above shows the <h2> is the heading two. In which, the <h2> is the element of h2, and the content is a heading 2. In which the content can be a text or other tags such as <link>, etc. Learn also HTML heading tags.

HTML elements

HTML Attribute

An HTML attribute is an additional information used in the opening tag. The information can be an instruction to give a color effect, thickness, etc. HTML attribute usually has two parts such as name and value. You can write an attribute with name = “value”. Writing a value in an HTML attribute is enclosed by two quotation marks, it could be quotation one ( ‘ ) or quotation two ( ” ).

Attribute writing in HTML begins with tagging, and in the tag, you need to provide an attribute and the element of the tag. Follow the example of HTML attribute writing below:

<!DOCTYPE html>
      <h2 align="center">Introduction to HTML attribute</h2>

Notice the syntax above:
<H2> is the tag of heading 2

  • align” is the name of the attribute
  • center” is the value of the attribute
  • Introduction to HTML attribute” is an element of the h2 tag

Not all tags require attributes in it. But if you want to learn web programming, you’ll often encounter tags with an attribute in each of them.

Subscribe to Our Newsletter!

Love Skillonpage? Get exclusive personalised content right in your Inbox. It's free!

You may also read!

Quick Way How to Remove Background Noise in Adobe Audition

It must be annoyed when your audio recordings have background noise. This article will show you how to remove


How to Curve Text in Photoshop by Creating Type on an Ellipse Path

You may have often seen the text in a circular pattern on a brochure or logo. Such curved text

5 Reasons why to choose PHP and MySQL to create a website.

5 Reasons to Choose PHP and MySQL to Build a Dynamic Website

This article will describe 5 big reasons why every web developer should choose PHP and MySQL to start building


Leave a reply:

Your email address will not be published.

Mobile Sliding Menu