html and css(1)

來源:互聯網
上載者:User

標籤:

 1 body{ 2     background-image:url(‘11.jpg‘); 3     background-color:yellow;         4     background-repeat:no-repeat;      5     background-attachment:fixed;     6     background-position:center; 7     background-origin:content-box; 8 } 9 10 11 /*    12 body{13     background-image:url(‘11.jpg‘);  //背景圖片14     background-color:yellow;           //背景顏色15     background-repeat:no-repeat;     //規定如何重複背景圖片16     background-attachment:fixed;     //規定背景圖片是否固定或者隨著頁面的其餘部分滾到17     background-position:center;      //規定背景圖片的位置18     background-size:cover;           //大小19     background-origin:content-box;         //相對於內容框來定位背景映像20     background-clip:content-box;        //規定背景的繪製地區21 }22 23 24 position:25 top left26 top center27 top right28 center left29 center center30 center right31 bottom left32 bottom center33 bottom right34 35 repeat:36 repeat    預設。背景映像將在垂直方向和水平方向重複。37 repeat-x    背景映像將在水平方向重複。38 repeat-y    背景映像將在垂直方向重複。39 no-repeat    背景映像將僅顯示一次。40 41 origin:42 padding-box    背景映像相對於內邊距框來定位。43 border-box    背景映像相對於邊框盒來定位。44 content-box    背景映像相對於內容框來定位。    45 46 clip:47 border-box    背景被裁剪到邊框盒。48 padding-box    背景被裁剪到內邊距框。49 content-box    背景被裁剪到內容框。50 51 attachment:52 scroll    預設值。背景映像會隨著頁面其餘部分的滾動而移動。53 fixed    當頁面的其餘部分滾動時,背景映像不會移動。54 inherit    規定應該從父元素繼承 background-attachment 屬性的設定。55 */

 

html and css(1)

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.