css clearfix (导航效果)

<div style="background-color: #337ab7">
            <div style="float: left">老男孩</div>
            <div style="float: right">图片</div>
        <div style="clear: both">
</
div>

.clearfix:after{
content: ".";
display: block;
height: 0;
clear: both;
visibility: hidden;
}
 

 

posted on 2015-12-20 21:45  zhaobin022  阅读(178)  评论(0编辑  收藏  举报