css float
This is the code
.float-wrapper::after {
content: "";
clear: both;
display: block;
}
---------------------------------------------------------------
Explanation:
.float-wrapper -> is some parent element that wraps the floating items
example:
<div class='float-wrapper'>
<div class='floating-item'> </div>
<div class='floating-item'> </div>
....
</div>
::after adds an element after the .float-wrapper, that
has no content and clears floats from the both sides, making sure,
other sections are not affected by floats
.myelement {
float: left;
}img
{
float: right;
}
Also in CSS:
- html5 video hide progress bar
- removing space between words css
- css thinner hr
- change css jquery
- svg css
- css font color
- css overwriting styles
- css to scss
- css border shorthand
- button css
- css multiple classes
- underline text using css
- access lamp folder using terminal mac
- using divs instead of table
- how to link fonts css
- css play button on image
- css background image cover center
- javascript css link append
- css transition visibility
- css font type
- css color picker
- scss hover
- how to underline font in css
- css rgb color