HTML paragraph
1. Definition
The so-called paragraph, the English word is "paragraph" and the label is
, which represents a paragraph in the text.
2. Grammar
Text content
3. Attribute
align, alignment . The values are: left (left), right (right), center (center).
Paragraph text
, this piece of code means that the text is left aligned.4. Note
1.
tags normally appear in pairs, although in actual use, only
is often seen but not< ;/p>, but Brother Hong still recommends that writing should be standardized.
2. The
tag is a segment, and the
tag is a line break. The main difference between the two is that the line spacing of the
tag is larger than that of the
tag.
3. The
tag is a block-level element.
Example:
php中文网(php.cn) 段落1
段落2
段落3
HTML line break
php中文网(php.cn) 这个
段落
演示了分行的效果
Note: The
element is an empty HTML element. Since a closing tag doesn't make any sense, it doesn't have a closing tag.
HTML Output - Usage Reminder
We cannot determine the exact effect of the HTML being displayed. The size of the screen, as well as adjustments to the window, may lead to different results.
With HTML, you cannot change the output by adding extra spaces or line breaks to the HTML code.
When displaying the page, the browser will remove extra spaces and blank lines in the source code. All consecutive spaces or empty lines are counted as one space. Note that all consecutive empty lines (newlines) in HTML code are also displayed as a single space.