Div does not surround content

HI I want to give my div some border, but when I create a box with all the borders, but the contents of the div are not surrounded !! Any suggestions?

+5
source share
2 answers

to try

 overflow: auto
+13
source

You should have floating content inside.

<div id="divWithBorderIssue">
   blah
   <div style="clear:both;"></div>
</div>

You can also use clearfix

edit: of course, if you provided the code, it would be easier for you to help

+1
source

All Articles