Home > Web Front-end > HTML Tutorial > css paragraph top and bottom spacing_html/css_WEB-ITnose

css paragraph top and bottom spacing_html/css_WEB-ITnose

WBOY
Release: 2016-06-24 12:20:45
Original
1022 people have browsed it

For example,

text text text



After the text is wrapped, how can you set the upper and lower spacing of p? Because it needs to be called dynamically, the br tag cannot be used.
The desired effect Yes
Text

Text

Text


Reply to Discussion (Solution)

.conten p{margin-bottom:10px;}
Copy after login

p {line-height:30px;}

p{line-height:1.5}

means that the line height of p is 1.5 times the height and width of p text

line-height :24px;Set line spacing

Thank you everyone, I haven’t written code for a long time, and I even forgot this.

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