Basic HTML Tags
Tag | Description |
---|---|
<html> | Describes an HTML document. |
<head> | Represents head section of the HTML document. |
<title> | Describes the title of HTML document. |
<body> | Describes content of the document. |
<!--...--> | This tag is used to insert comment inside document code. |
We have explained about HTML head tag here.
HTML Heading Tags
Tag | Description |
---|---|
<h1> | This is the highest heading 1 |
<h2> | Second level heading 2 |
<h3> | Third level heading 3 |
<h4> | Fourth level heading 4 |
<h5> | Fifth level heading 5 |
<h6> | This is the least heading 6 |
HTML Link Tags
Tag | Description |
---|---|
<base> | Describes the base URL to all other relative URLs. |
<a> | Specifies a hyperlink. |
For more details about HTML Link Tags refer here.
HTML Scripting Tags
Tag | Description |
---|---|
<script> | Describes client- side script that is JavaScript. |
<noscript> | When scripts are disabled <noscript> tag provides alternative details to the users. |
Everything about HTML Scripting Tags.
HTML Table Tags
Tag | Description |
---|---|
<table> | To define a Table in HTML. |
<caption> | To define a Table caption in HTML. It is like a name of the table |
<th | th is like "Table Head" to specify the header cell in the table. It is used to provide the Column name of a table. |
<tr> | tr is like "Table Row" to specify the row in a table. It is used for each row of a table. |
<td> | td is like "Table Data" to specify a cell in a table. |
<thead> | thead is like "Table Head" used to change the properties like the color of the Header content in HTML table. We can change the properties of the heading. |
<tbody> | tbody is like "Table Body" used to change the properties like the color of the content in the body in HTML table. We can change the properties of the body. |
<tfoot> | tfoot is like "Table footer" used to change the properties like the color of the footer content in HTML table. We can change the properties of a footer. |
<col> | Defines the properties of each column within colgroup. |
<colgroup> | It is used to specify a group of one or more columns in a table for formatting. |
Refer HTML Table Tag for more details.
HTML Form Tags
Tag | Description |
---|---|
<form> | Form is used in all the websites to collect information about user who visits your website. |
<input> | It is an input field where user can give there details in the given form. |
<textarea> | Represent a multi-line plain-text editing control. |
<button> | Creates various clickable buttons like submit, reset, cancel, ok and many more. |
<select> | Describes a drop-down list. |
<optgroup> | Display group of options related lists in the form of drop down list. |
<option> | Displays option in drop down list. |
<label> | Describes text label with a form input field. |
<fieldset> | To form related data in group <fieldset> element is used. |
<legend> | Represent caption of <fieldset> element. |
<datalist> | The pre-defined option is specified in drop down list. |
<output> | Declares results of calculation. |
We have explained more about HTML Form Tags.
HTML Text Tags
Tag | Description |
---|---|
<abbr> | Specifies abbreviations. |
<address> | We can provide contact details of page author using address element. |
<b> | It is used to bold text. |
<bdi> | BDI means Bi-Directional Isolation. It formats the text in different direction. |
<bdo> | Describes bi-directional override of the text. |
<blockquote> | The HTML blockquote element is used to format a block of text as a long quote which is indented more than the surrounding text. |
<cite> | It specifies the work title. |
<code> | Specifies text in computer code. |
<del> | It defines deleted text in HTML document. |
<dfn> | This tag is used for definition term in HTML. |
<em> | Formats text in document to emphasized text. |
<i> | Formats text in document to italic text. |
<ins> | ins describes inserted text in HTML document. |
<kbd> | Denotes the text given by user that is keyboard input. |
<mark> | marks the text. |
<meter> | Within the predefined range <meter> tag specifies scalar measurement known as gauge. |
<pre> | Describes preformatted text in HTML page. It is used to maintain the existing spaces or line breaks. |
<progress> | Progress of any task is defined by progress bar. |
<q> | Declares short quotations. |
<rp> | This tag is used to help browsers which is not supported by ruby annotation. |
<rt | Specifies Character pronunciation of ruby annotations. |
<ruby> | Specifies a ruby annotation which is used to show many East Asian languages. |
<s> | Specifies that given text is incorrect and it strike through text. |
<samp> | Describes sample output from computer program. |
<small> | Describe smaller text. |
<strong> | Used for describing important text. |
<sub> | We can give subscript to text. |
<sup> | used for giving superscripted to text. |
<template> | For a template. |
<time> | Specifies date and time in HTML document. |
<tt> | Describe teletype text. |
<var> | Specifies name of variable in mathematical expression or programming context. |
<wbr> | Specifies position within text where browser may optionally break a line. |
HTML Image Tags
Tag | Description |
---|---|
<img> | Represents an image. |
<map> | Represent map within <img> tag. And the image map contains clickable areas. |
<area> | It is used to define area inside an image-map, where it contains clickable region on an image map. |
<canvas> | This tag in HTML5 is used to draw graphics on web page using JavaScript. |
<figcaption> | This tag gives Caption to figure element. This can be placed as first or last child of <figure> element. |
<figure> | It defines media content with captions. Content of <figure> element belongs to main flow. |
<svg> | It is a language used to describe 2D graphics and graphical applications in XML. |
Refer HTML Image Tags for more information
HTML Meta Tags
Tag | Description |
---|---|
<head> | Represents head section of the HTML document which contains the meta information about the HTML Page |
<meta> | Describes the metadata of HTML page where it contains page description, author of the page, keywords. |
<base> | Describes the base URL to all other relative URLs. |
<basefont> | This tag is used to specify font size, color and font family for the document. (Deprecated) |
you can click here for more explanation about Meta Tags
HTML Object Tags
Tag | Description |
---|---|
<object> | It is used to embed multimedia in HTML documents like video, audio, Java applets, ActiveX, PDF, and Flash. |
HTML List Tags
Keyword Parameters are those parameters which does not follow a fixed position and can appear in any position or order. You can change the position of the keyword parameters as you wish.
Tag | Description |
---|---|
<ul> | Tag is used for unordered list. The list will have items as bulleted items |
<ol> | Represents an ordered list in either Numeric or alphabetical order |
<li> | It represents an item or items in a list. We can list the term and term description below this |
<dl> | Used for description list. |
<dt> | For Term in the description list. |
<dd> | This tag represents Term description in the description list. |
<menu> | Represents the list of commands which is used to build menus. |
<menuitem> | Represents the command that the user can invoke from a popup menu. |
We have explained about HTML Lists here in details
Unclosed HTML Tags
Tag | Description |
---|---|
<hr> | Represents thematic break between paragraph-level elements in the HTML document. If we use this, it will insert a horizontal line. |
<br> | It is used to break a line(line break). |
To know more about Unclosed Tags click here
Interview Questions & Answer
Tag is an HTML code that defines every structure on an HTML page. Tags begin with “<>” and end with “</>”. Most of the tag contains opening and closing tag.
For example,
…….
<> – Opening tag.
</> – Closing tag.
Most of the HTML tags have a closing tag as well but there are few HTML tags/elements that do not require closing tags and they are:-
<br>- break line
<hr> – horizontal line
There are 6 headings in HTML:-
<h1>……</h1>
<h2>……</h2>
<h3>……</h3>
<h4>……</h4>
<h5>……</h5>
<h6>……</h6>
There are three tags that can be used to separate a section of texts.
<br> – For line break.
<hr>- To separate Paragraph.
<q>- For large quoted section.