In this illustration we will introduce you about the <div> tag in html5. The <div> tag is used to define the section in html document. We can group the element as a block by <div> tag and can be formatted using styles. The <div> tag offtenly use css for formatting.
The declaration syntax of <div> tag is as follows:
|<div>Element to be group</div>|
The elements to be grouped are written inside the <div> tag and must use oppening and closing tag.
<title>Example of div Tag</title>
<dd> We work on java technology</dd>
<dd> Master of Computer Application</dd>
Difference between HTML5 and HTML4.01:
There is no element specific attribute in HTML5. In html4.01 this tag is used for defining the navigational section but in the html5 some new tags like <article>,<header>,<footer>,<aside> etc replaces the <div> tag have been introduced. We should use new tags as much as possible, the <div> tag must be used at last when other tag is not suitable.
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.