Tuesday, March 19, 2013

Using the .after pseudo-element clearfix a positioned div- css trick

0 comments
When you are using a div positioned content will not show outside the bounds of the container. using the following css we can clear this thing.
.container {
    display: inline-block;
}
.container:after {
    content: " ";
    display: block;
    height: 0;
    clear: both;
    overflow: hidden;
    visibility: hidden;
}
.container {
    display: block;
}
for internet browser using the following code


Read more...