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

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

如何在不添加太多內(nèi)容的情況下增加圖像的背景尺寸?

如何在不添加太多內(nèi)容的情況下增加圖像的背景尺寸?

慕桂英546537 2023-12-11 16:02:22
我正在嘗試在背景上添加背景圖像,我可以做到這一點(diǎn),但它沒(méi)有顯示我使用此代碼的圖像的完整尺寸。當(dāng)我嘗試使用背景大小自動(dòng)時(shí),我得到了正確的寬度,但高度很小,我知道這取決于內(nèi)容大小。但還是有什么辦法<div style="background: url('https://firebasestorage.googleapis.com/v0/b/growthfilepractice.appspot.com/o/1%20(2).jpg?alt=media&token=48244df9-a2bb-412a-81f5-854e2dbc4939');background-repeat: no-repeat;background-size:500px 500px;">  <a href ="https://github.com/" style="text-decoration: none;">    <table>      <tr>        <td><h3 style="color: #fff;">Amarjeet Singh</h3></td>      </tr>      <tr>      </tr>    </table>  </a></div>
查看完整描述

2 回答

?
慕絲7291255

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

該圖像被設(shè)置為您的背景<div>,因此它的大小將取決于該圖像的width和。因此,如果高度較大,則會(huì)顯示更多內(nèi)容。只是為了說(shuō)明,請(qǐng)檢查下面我的代碼。我已經(jīng)給出了a ,現(xiàn)在圖像顯示了該高度。height<div>background-image<div>height : 600px


因此,簡(jiǎn)而言之,您的背景圖像僅顯示元素的大小。元素越大,圖像就會(huì)出現(xiàn)越多。


<div  class="container" 

      style=" height: 600px; /* Just to illustrate */

              position: relative;

              background: url('https://firebasestorage.googleapis.com/v0/b/growthfilepractice.appspot.com/o/1%20(2).jpg?alt=media&token=48244df9-a2bb-412a-81f5-854e2dbc4939');

              background-repeat: no-repeat;

            background-size:500px 500px;">

  <a  class="nameAnchor" 

      href ="https://github.com/" 

      style=" text-decoration: none;

              position: absolute;

              color: white;

              left: 10px; /* Set your Left position here */

              top: 100px; /* set your top position here */

  ">

    <span>Amarjeet Singh</span>

  </a>

</div>


查看完整回答
反對(duì) 回復(fù) 2023-12-11
?
絕地?zé)o雙

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

我建議你設(shè)置背景大?。悍饷?。如果您想要的話(huà),這會(huì)自動(dòng)將其設(shè)置為完整尺寸。



查看完整回答
反對(duì) 回復(fù) 2023-12-11
  • 2 回答
  • 0 關(guān)注
  • 154 瀏覽

添加回答

舉報(bào)

0/150
提交
取消
微信客服

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

幫助反饋 APP下載

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

公眾號(hào)

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