Home >Web Front-end >HTML Tutorial >What is div tag?

What is div tag?

云罗郡主
云罗郡主Original
2019-01-30 14:34:5719123browse

What is the tag of div

DIV is the positioning technology in cascading style sheets, the full name is DIVision, which means division. Sometimes they are called layers. DIV is also called integer divisibility in programming, that is, only the integers of the quotient can be obtained. The DIV element is an element used to provide structure and background for block-level content within an HTML (an application under Standard Universal Markup Language) document. [Recommended reading: HTML video tutorial]

What is div tag?

Function: Define the division or section (division/section) in the document.

Note: dc6dce4a544fdca2df29d5ac0ea9906b is a block-level element. This means that its contents automatically start on a new line. In fact, line breaks are the only formatting behavior inherent to dc6dce4a544fdca2df29d5ac0ea9906b. Additional styles can be applied via the dc6dce4a544fdca2df29d5ac0ea9906b's class or id. It is not necessary to add a class or id to every dc6dce4a544fdca2df29d5ac0ea9906b, although there are certain advantages to doing so. It is possible to apply either class or id attributes to the same dc6dce4a544fdca2df29d5ac0ea9906b element, but it is more common to apply only one or the other. The main difference between the two is that class is used for groups of elements (similar elements, or can be understood as a certain type of elements), while id is used to identify individual and unique elements.

Note: The dc6dce4a544fdca2df29d5ac0ea9906b tag can divide the document into independent and different parts. It can be used as a strict organizational tool and does not use any formatting associated with it. The dc6dce4a544fdca2df29d5ac0ea9906b tag is supported by all major browsers.

html div tag example

<html>
<body>
<h3>This is a header</h3>
<p>This is a paragraph.</p>
<div style="color:#FF0000">
<h3>This is a header</h3>
<p>This is a paragraph.</p>
</div>
</body>
</html>


The above is the detailed content of What is div tag?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn