61,115
社区成员
发帖
与我相关
我的任务
分享
/* font-size:0;letter-spacing:-6px;解决换行间距bug 火狐私有 display:-moz-inline-box */
.gib {position: relative;display: -moz-inline-box;display: inline-block; font-size:0px; letter-spacing:-6px;}
/* IE hack */
* html .gib {display: inline;}
*:first-child+html .gib {display: inline;}
.cBox{ margin-left:auto; margin-right:auto;}
.cBox{ width:730px; height:452px; padding:5px 5px 5px 5px;}
.left{ width:200px; height:450px; margin-left:5px;}
.mid{ width:300px; height:450px; margin-left:5px;}
.right{ width:200px; height:450px; margin-left:5px;}
<div class="cBox">
<div class="c gib">
<div class="left gib"></div>
<div class="mid gib"></div>
<div class="right gib"></div>
</div>
</div>
/*
* Default rule; only Safari, Webkit, and Opera handle it without hacks.
*/
.gib {
position: relative;
display: -moz-inline-box; /* Ignored by FF3 and later. */
display: inline-block;
font-size:0px;
letter-spacing:-6px;
}
/*
* Pre-IE7 IE hack. On IE, "display: inline-block" only gives the element
* layout, but doesn't give it inline behavior. Subsequently setting display
* to inline does the trick.
*/
* html .gib {
display: inline;
}
/*
* IE7-only hack. On IE, "display: inline-block" only gives the element
* layout, but doesn't give it inline behavior. Subsequently setting display
* to inline does the trick.
*/
*:first-child+html .gib {
display: inline;
}