background

英 [ˈbækgraʊnd]   美 [ˈbækˌɡraʊnd]  

n.(画等的)背景;底色;背景资料;配乐

复数: backgrounds

repeat

英 [rɪˈpi:t]   美 [rɪˈpit]  

vt.重复;复述,背诵

vi.重做;重复投票

n.重复;(节目)重演;重复的事物

第三人称单数: repeats 复数: repeats 现在分词: repeating 过去式: repeated 过去分词: repeated

css background-repeat属性 语法

background-repeat属性怎么用?

CSS中background-repeat属性是用来设置背景图像如何平铺。background-repeat:repeat-x;表示只有水平位置会重复背景图像;background-repeat:repeat-y;表示只有垂直位置会重复背景图像。

作用:设置是否及如何重复背景图像。

说明:background-repeat 属性定义了图像的平铺模式。从原图像开始重复,原图像由 background-image 定义,并根据 background-position 的值放置。

注释:任何版本的 Internet Explorer (包括 IE8)都不支持属性值 "inherit"。

css background-repeat属性 示例

<html>
<head>
<style type="text/css">
body
{ 
background-image: 
url(http://img.php.cn/upload/article/000/005/656/5af270fd37755429.jpg);
background-repeat: repeat-y
}
</style>
</head>
<body>
</body>
</html>

运行实例 »

点击 "运行实例" 按钮查看在线实例

热门推荐