亚洲最大看欧美片,亚洲图揄拍自拍另类图片,欧美精品v国产精品v呦,日本在线精品视频免费

  • 站長資訊網(wǎng)
    最全最豐富的資訊網(wǎng)站

    css怎樣實現(xiàn)DIV高度自適應

    css怎樣實現(xiàn)DIV高度自適應

    可以添加表格特性。

    (推薦教程:CSS教程)

    父級元素添加屬性 display: table;

    子一級元素添加屬性 display: table-cell;

    代碼:

    <div class="div-row">         <style type="text/css">             .div-row {                 width: 400px;                 border: 1px solid #23527C;                 display: table;             }             .div-col {                 display: table-cell;             }         </style>               <div class="div-col" style="background-color: #28A4C9;">                 <p><span>內(nèi)容1</span></p>             </div>             <div class="div-col"  style="background-color: #31B0D5;">                 <p><span>內(nèi)容1</span></p>                 <p><span>內(nèi)容2</span></p>             </div>             <div class="div-col"  style="background-color: #269ABC;">                 <p><span>內(nèi)容1</span></p>                 <p><span>內(nèi)容2</span></p>                 <p><span>內(nèi)容3</span></p>             </div>             <div  class="div-col" style="background-color: #5BC0DE;">                 <p><span>內(nèi)容1</span></p>                 <p><span>內(nèi)容2</span></p>                 <p><span>內(nèi)容3</span></p>                 <p><span>內(nèi)容4</span></p>                 <p><span>...</span></p>             </div>         </div>

    結果:

    css怎樣實現(xiàn)DIV高度自適應

    贊(0)
    分享到: 更多 (0)
    網(wǎng)站地圖   滬ICP備18035694號-2    滬公網(wǎng)安備31011702889846號