2013-12-20 81 views
0

问题和问题显示:在Firefox表溢出父DIV

当使用显示:表并显示:表小区到垂直对齐一个元件,火狐溢出父容器宽度。查看现场演示来检查代码。

HTML

<div class="hew storeloader" href="/stores/arti-zen-eskilstuna-city"> 
    <div class="holder hp100" style="height: 325px;"> 
     <div class="storecontent"> 
      <img alt="" src="/img/logo-white.svg"> 
      <p>Arti.Zen Eskilstuna City</p> 
     </div> 
    </div> 
</div> 

CSS

section.stores .storeloader { 
    width: 47.82609%; 
    float: left; 
    margin-right: 4.34783%; 
    display: inline; 
    overflow: hidden; 
    background: #000; 
    color: #FFF; 
    text-align: center; 
    margin: 10px 0; 
    position: relative; 
    cursor: pointer; 

section.stores .storeloader .holder { 
    width: 100%; 
    display: table; 
} 
section.stores .storeloader .holder .storecontent { 
    display: table-cell; 
    padding: 0 10px; 
    text-align: center; 
    vertical-align: middle; 
    text-transform: capitalize; 
    font-size: 20px; 
} 
+0

它在Chrome工作在这里很好的容器上解决。你能告诉我们一个Firefox的预览? –

+0

和Firefox上。 –

+0

使用'display:table'在容器上'table-layout:fixed;'解决。 – user1885523

回答