第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號(hào)安全,請(qǐng)及時(shí)綁定郵箱和手機(jī)立即綁定
已解決430363個(gè)問(wèn)題,去搜搜看,總會(huì)有你想問(wèn)的

此段代碼如何將div置于窗口底部

此段代碼如何將div置于窗口底部

一只斗牛犬 2019-03-08 18:15:57
想把整個(gè)swiper-container置于距窗口底部30px,但設(shè)置bottom無(wú)效,高手請(qǐng)賜教<html> <head>   <meta charset="utf-8" />   <link rel="stylesheet" href="http://www.swiper.com.cn/dist/css/swiper.min.css" />   <style>    body {      font-family: Helvetica Neue, Helvetica, Arial, sans-serif;      font-size: 14px;      color:#000;      margin: 0;      padding: 0;    }    .swiper-container {      width:100%;      height:100%;      max-width:580px;    }    .swiper-slide {      background-position: center;      background-size: cover;      width: 100px;      height:100px;    }  </style>  </head>  <body>   <div class="swiper-container">    <div class="swiper-wrapper">     <div class="swiper-slide" style="background-color:red"></div>     <div class="swiper-slide" style="background-color:blue"></div>     <div class="swiper-slide" style="background-color:green"></div>     <div class="swiper-slide" style="background-color:gray"></div>    </div>   </div>   </body></html>
查看完整描述

3 回答

?
MYYA

TA貢獻(xiàn)1868條經(jīng)驗(yàn) 獲得超4個(gè)贊

.swiper-container {

  height:100px;

  max-width:580px;

      position: fixed;

      bottom: 30px;

      left: 50%;

  transform: translate(-50%);

}


查看完整回答
反對(duì) 回復(fù) 2019-03-18
?
揚(yáng)帆大魚(yú)

TA貢獻(xiàn)1799條經(jīng)驗(yàn) 獲得超9個(gè)贊

.swiper-container {

    width: 100%;

    height: 100%;

    max-width: 580px;

    position: absolute;

    bottom: 30px;

}


查看完整回答
反對(duì) 回復(fù) 2019-03-18
?
RISEBY

TA貢獻(xiàn)1856條經(jīng)驗(yàn) 獲得超5個(gè)贊

你要父元素和子元素同時(shí)整個(gè)定位,他才能有效啊,這樣當(dāng)然不能拉


查看完整回答
反對(duì) 回復(fù) 2019-03-18
  • 3 回答
  • 0 關(guān)注
  • 599 瀏覽
慕課專欄
更多

添加回答

舉報(bào)

0/150
提交
取消
微信客服

購(gòu)課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動(dòng)學(xué)習(xí)伙伴

公眾號(hào)

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號(hào)