Home > Web Front-end > HTML Tutorial > HTML segmentation and line breaking code instructions

HTML segmentation and line breaking code instructions

黄舟
Release: 2016-12-21 15:59:50
Original
8891 people have browsed it

In the layout of web pages, text is often segmented and line-wrapped. These two operations are implemented by the

tag and the
tag.

1.

-Paragraph tag

p is the first letter of the English word "paragraph", which is used to define a section of text in a web page.

usually appears in pairs.

2.
-Line break tag

br is the abbreviation of the English word "break". Its function is to force text to a new line in a paragraph.
is a self-closing tag. The standard writing method is
.

tags and
tags both cause text to wrap. The difference is that their spacing is different. The spacing between segments using the

tag is larger and the levels are clearer.

Example:

1
2
3
4
5
6
7
8
9
10
11
/head>

html text content

html text content

html text content
html text content


It can be seen from the browser that the text line spacing defined by the p tag and the br tag is different.

Tips: You cannot adjust the spacing of paragraphs just by using html. If you want to adjust them, you will need to use css. This site will introduce it in the following tutorials.


The above is the description of HTML segmentation and line breaking codes. For more related content, please pay attention to the PHP Chinese website (www.php.cn)!


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 admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template