HTML tag, Element and Attribute in English

What are the HTML Tags, Attributes and Elements

HTML Tags, Attributes and Elements क्या हैं

Let's see first what are the html tags


HTML Tags

HTML Tags: Tags are the starting parts and ending parts of an HTML element. They begin with < symbol and end with > symbol. Whatever written inside < and > are called tags.


Html tags are used to define that how web browser will format and display the content on screen. HTML tags helps to distinguish between an html content and a simple content.

When a web browser reads an HTML document, browser reads it from top to bottom and left to right. HTML tags are used to create HTML documents and render their properties. Each HTML tags have different properties.

An HTML file must have some essential tags so that web browser can differentiate between a simple text and HTML text. You can use as many tags you want as per your code requirement.

Example: 

H1 level one heading tag है 

<h1> </h1> 

Where, <h1> is the starting tag and </h1> is the ending tag.


HTML Elements

HTML elements: generally an HTML element usually consist of a start tag <tag name>, close tag </tag name> and contains content between them. 

So it means an element is a collection of start tag, attributes, end tag, and content between them.

These elements are responsible for creating web pages and define content in that webpage.

Example: 

<b>This is the content.</b> 
This is the content.

Where, <b> is the starting tag and </b> is the ending tag.

HTML Attributes

HTML Attributes: Attribute is used to define the character of an HTML element. It always placed in the opening tag of an element. It generally provides additional styling (attribute) to the element.

Each element or tag can have attributes, which defines the behaviour of that element.

The Attributes name and values are case sensitive, and it is recommended by W3C that it should be written in Lowercase only.

You can add multiple attributes in one HTML element, but need to give space between two attributes.


Example: 

<p align="center">This is paragraph.</p> 
This is paragraph.







टिप्पणियाँ

इस ब्लॉग से लोकप्रिय पोस्ट

Redmi K30i 5G को स्नैपड्रैगन 765G और 120Hz डिस्प्ले के साथ घोषित किया गया है: कीमत, स्पेसिफिकेशन और बहुत कुछ

HTML Tag, Attribute and Element in detail हिन्दी में।