css 水平居中的办法

<div style="width: 100%; text-align: center; margin: auto;">
<div style="display: inline-block;">
<div style="width: 100px; height: 100px; float: left;">sadf</div>
<div style="width: 100px; height: 100px; float: left;">sadf</div>
</div>
</div>

posted @ 2015-12-22 14:40  smght  阅读(154)  评论(0)    收藏  举报