How to set hr in html

藏色散人
Release: 2023-01-03 09:32:06
Original
6989 people have browsed it

htmlHow to set hr: First create an HTML sample file; then enter some text content in the body; finally add the "


" tag between the paragraphs that need to be separated to create a horizontal line.

How to set hr in html

The operating environment of this tutorial: Windows7 system, HTML5&&CSS3 version, Dell G3 computer.


Definition and Usage

The


tag creates a horizontal line in an HTML page.

Horizontal rule (horizontal rule) can visually separate the document into various parts.

Differences between HTML and XHTML

In HTML, the


tag does not have a closing tag.

In XHTML,


must be closed correctly, such as
.

In HTML 4.01, all rendering attributes of the hr element are deprecated.

In XHTML 1.0 Strict DTD, all rendering attributes of the hr element are not supported.

Optional attributes

How to set hr in html

Example

Titles and paragraphs separated by horizontal lines:




hr 标签定义水平线:


这是段落。


这是段落。


这是段落。

Copy after login

The effect is as follows:

How to set hr in html

Recommended learning: "HTML video tutorial""css video tutorial"

The above is the detailed content of How to set hr in html. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
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 [email protected]
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!