css教程:CSS背景background屬性的應(yīng)用_CSS教程
教程Tag:暫無Tag,歡迎添加,賺取U幣!
The CSS background properties define the background effects of an element.
CSS的background屬性可為元素定義背景效果。
設(shè)置背景顏色 Set the background color
This example demonstrates how to set the background color for an element.
實(shí)例:
[ 可先修改部分代碼 再運(yùn)行查看效果 ]
設(shè)置背景圖片 Set an image as the background
This example demonstrates how to set an image as the background
實(shí)例:
[ 可先修改部分代碼 再運(yùn)行查看效果 ]
重復(fù)背景圖片 How to repeat a background image
This example demonstrates how to repeat a background image.
實(shí)例:
[ 可先修改部分代碼 再運(yùn)行查看效果 ]
背景圖片水平重復(fù) How to repeat a background image only horizontally
This example demonstrates how to repeat a background image only horizontally.
實(shí)例:
[ 可先修改部分代碼 再運(yùn)行查看效果 ]
背景圖片垂直重復(fù) How to repeat a background image only vertically
This example demonstrates how to repeat a background image only vertically.
實(shí)例:
[ 可先修改部分代碼 再運(yùn)行查看效果 ]
圖片放在頁面上 How to place the background image
This example demonstrates how to place the image on the page.
實(shí)例:
[ 可先修改部分代碼 再運(yùn)行查看效果 ]
背景圖片固定在背景上,不跟隨頁面一起移動(dòng) How to set a fixed background image
This example demonstrates how to set a fixed background image. The image will not scroll with the rest of the page.
實(shí)例:
[ 可先修改部分代碼 再運(yùn)行查看效果 ]
一句聲明就能設(shè)置所有與background屬性有關(guān)的值 All the background properties in one declaration
This example demonstrates how to use the shorthand property for setting all of the background properties in one declaration.
實(shí)例:
[ 可先修改部分代碼 再運(yùn)行查看效果 ]
CSS的background屬性可為元素定義背景效果。
設(shè)置背景顏色 Set the background color
This example demonstrates how to set the background color for an element.
實(shí)例:
代碼調(diào)試框 [hl5o.cn]
[ 可先修改部分代碼 再運(yùn)行查看效果 ]
設(shè)置背景圖片 Set an image as the background
This example demonstrates how to set an image as the background
實(shí)例:
代碼調(diào)試框 [hl5o.cn]
[ 可先修改部分代碼 再運(yùn)行查看效果 ]
重復(fù)背景圖片 How to repeat a background image
This example demonstrates how to repeat a background image.
實(shí)例:
代碼調(diào)試框 [hl5o.cn]
[ 可先修改部分代碼 再運(yùn)行查看效果 ]
背景圖片水平重復(fù) How to repeat a background image only horizontally
This example demonstrates how to repeat a background image only horizontally.
實(shí)例:
代碼調(diào)試框 [hl5o.cn]
[ 可先修改部分代碼 再運(yùn)行查看效果 ]
背景圖片垂直重復(fù) How to repeat a background image only vertically
This example demonstrates how to repeat a background image only vertically.
實(shí)例:
代碼調(diào)試框 [hl5o.cn]
[ 可先修改部分代碼 再運(yùn)行查看效果 ]
圖片放在頁面上 How to place the background image
This example demonstrates how to place the image on the page.
實(shí)例:
代碼調(diào)試框 [hl5o.cn]
[ 可先修改部分代碼 再運(yùn)行查看效果 ]
背景圖片固定在背景上,不跟隨頁面一起移動(dòng) How to set a fixed background image
This example demonstrates how to set a fixed background image. The image will not scroll with the rest of the page.
實(shí)例:
代碼調(diào)試框 [hl5o.cn]
[ 可先修改部分代碼 再運(yùn)行查看效果 ]
一句聲明就能設(shè)置所有與background屬性有關(guān)的值 All the background properties in one declaration
This example demonstrates how to use the shorthand property for setting all of the background properties in one declaration.
實(shí)例:
代碼調(diào)試框 [hl5o.cn]
[ 可先修改部分代碼 再運(yùn)行查看效果 ]
相關(guān)CSS教程:
- 相關(guān)鏈接:
- 教程說明:
CSS教程-css教程:CSS背景background屬性的應(yīng)用
。