How to style HTML paragraphs with CSS to prevent empty lines between them?
css, html, paragraph, xhtml
Solution
Remove the top and bottom margins:
p{
margin-top:0;
margin-bottom:0
}
Problem
If I have 2 complete, successive paragraphs, how should I style them so that there is only one line break (so no empty line) between them? E.g. ``` <p>First paragraph</p> <p>Second paragraph</p> ``` Should render as ``` First paragraph Second paragraph ``` I am generating this HTML with XSLT.