HTML basics summary recommendation (paragraph)

HTML basics summary recommendation (paragraph)

HTML Paragraph

Paragraphs are defined by the <p> tag.

Examples

<p>This is a paragraph</p>
<p>This is another paragraph</p>

Tip: Forgetting to use a closing tag can produce unexpected results and errors.

The align attribute of <p> is deprecated in HTML4/5. Please use CSS instead. Paragraphs support event attributes and global attributes

Text alignment within a paragraph

<!DOCTYPE html>
<html>
<head>
<style>
h1 {text-align:center;}
p.date {text-align:right;}
p.main {text-align:justify;}
</style>
</head>

<body>

<h1>CSS text-align example</h1>
<p class="date">March 14, 2015</p>
<p class="main">"When I was young, I dreamed of changing the world. When I grew older, I found that I could not change the world, so I shortened my sights and decided to change only my country. When I entered my twilight years, I found that I could not change our country. My last wish was just to change my family. But, that too could not happen. Now, as I lie on my bed, dying, I suddenly realize: If I had just changed myself first, then I might have changed my family. With their help and encouragement, I might have done something for my country. Then, who knows? I might even have changed the world."</p>
<p><b>Note:</b> Resize your browser window to see how &quot;justify&quot; works. </p>
</body>
</html>

grammar
<p align="left|right|center|justify">

Property Value

描述
left 左對齊文本。
right 右對齊文本。
center 居中對齊文本。
justify 對行進行伸展,這樣每行都可以有相等的寬度(就像在報紙和雜志中)。

HTML line breaks

If you want a line break (new line) without creating a new paragraph, use the <br /> tag:

Examples

<p>This is<br>a para<br>graph with line breaks</p>
The <br /> element is an empty HTML element. Since a closing tag doesn't make any sense, it doesn't have a closing tag.

Tip: <br> tags are very useful when writing address information or poetry. Note: Use the <br> tag to enter a blank line instead of breaking a paragraph. Note: HTML output - Use caution as we cannot determine exactly how the HTML will be displayed. The size of the screen and the resizing of the window may lead to different results. With HTML, you cannot add extra spaces or line breaks in the HTML code to change the output. When displaying a page, the browser removes extra spaces and blank lines from the source code. All consecutive spaces or blank lines are counted as one space. It is important to note that all consecutive blank lines (newlines) in HTML code are also displayed as one space. <html>

<body>
<h1>Spring Dawn</h1>
<p>
I sleep through the spring without knowing the dawn,
Birds can be heard everywhere.
The sound of wind and rain at night,
How many flowers have fallen?
</p>
<p>Note that browsers ignore the typography in the source code (eliminating extra spaces and line breaks). </p>
</body>
</html>

Output

Spring Dawn

I slept through the spring without knowing the dawn, and heard birds singing everywhere. There was a sound of wind and rain at night, and I wonder how many flowers have fallen.

Note that browsers ignore typography in the source code (eliminating extra spaces and line breaks).

The above HTML basic summary recommendation (paragraph) is all the content that the editor shares with you. I hope it can give you a reference. I also hope that you will support 123WORDPRESS.COM.

Original URL: http://www.cnblogs.com/sxtywjx/archive/2016/07/13/5665124.html

<<:  The whole process of installing gogs with pagoda panel and docker

>>:  Detailed introduction to the MySQL installation tutorial under Windows

Recommend

Boundary and range description of between in mysql

mysql between boundary range The range of between...

MySQL 8.0.17 installation and simple configuration tutorial under macOS

If you don’t understand what I wrote, there may b...

Solve the problem that ifconfig and addr cannot see the IP address in Linux

1. Install the Linux system on the virtual machin...

Example code for implementing a pure CSS pop-up menu using transform

Preface When making a top menu, you will be requi...

Tutorial on upgrading from Centos7 to Centos8 (with pictures and text)

If you upgrade in a formal environment, please ba...

How to configure Http, Https, WS, and WSS in Nginx

Written in front In today's Internet field, N...

Vue implements adding watermark effect to the page

Recently, when I was working on a project, I was ...

HTML table tag tutorial (20): row background color attribute BGCOLOR

The BGCOLOR attribute can be used to set the back...

Instructions for using MySQL isolation Read View

Which historical version can the current transact...

isPrototypeOf Function in JavaScript

Table of contents 1. isPrototypeOf() Example 1, O...

Detailed Tutorial on Installing VirtualBox 6.0 on CentOS 8 / RHEL 8

VirtualBox is a free and open source virtualizati...

mysql installer community 8.0.12.0 installation graphic tutorial

This tutorial shares the installation of mysql in...