Reputation: 39
Below is my code:
<div style="float: left; margin-left: 50px; margin-bottom: 50px"><img src="06fc499c-5329-419c-b0df-644ee5d8439b_icon48.png"></div>
<br/>
<div> <strong>1</strong> <a href="1">2</a> <a href="2">></a> </div>
I found that style="float: left; margin-left: 50px; margin-bottom: 50px" that causes all on the same line, when i remove the style="float: left; margin-left: 50px; margin-bottom: 50px"
,
The line break after <br/>
tag operates normally. However, I wanted to keep ` style="float: left; margin-left: 50px; margin-bottom: 50px" from the beginning. How do I use the line break in this case?
Thanks so much for advice.`
Upvotes: 0
Views: 6069
Reputation: 39
Fixed by adding style="clear: both"
which makes the element drop below any floated elements that precede it in the document.
Upvotes: 1