版: CSS1 JavaScript语法: object .style.backgroundRepeat="repeat-x" Try it 浏览器支持 在表中的数字规定,完全支持该属性的第一个浏览器版本。 属性 background-repeat 1.0 4 1.0 1.0 3.5 Note: IE8和更早的版本不一个元素上支持多个背景图像。CSS...
This CSS tutorial explains how to use the CSS property called background-repeat with syntax and examples. The CSS background-repeat property defines whether the background-image for an element is repeated (ie: tiled).
CSS | background-repeat Property CSS 中的 background-repeat 属性用于水平和垂直重复背景图像。它还决定背景图像是否会重复。语法 background-repeat: repeat|repeat-x|repeat-y|no-repeat|initial| inherit; 默认值:它的默认值是初始值。 属性值repeat:此属性用于水平和垂直重复背景图像。如果最后一张图像不适合...
background-repeatproperty body{background-image:url("https://media.geeksforgeeks.org/wp-content/uploads/geeks-25.png");background-repeat:no-repeat;background-size:400px250px;text-align:center; } GeeksforGeeks background-repeat:no-repeat; 输出: 支持的浏览器:background-repeat属性支持的浏...
background-image:url("paper.gif"); background-repeat:repeat-y; } Try it yourself » More "Try it Yourself" examples below. Definition and Usage The background-repeat property sets if/how a background image will be repeated. By default, a background-image is repeated both vertically and...
The background-repeat property can also be used with multiple background images (i.e. if you specify multiple values for the background-image property).Syntaxbackground-repeat: <repeat-style> [ , <repeat-style> ]*Where<repeat-style> = repeat-x | repeat-y | [repeat | space | round |...
background-position: top rightcombined withbackground-repeat: no-repeat. Background repeat can also be specified as part of thebackgroundshorthand property. Possible Values ValueDescriptionExample repeatTiled. Repeating the image both horizontally and vertically. Default behavior. ...
The background-repeat CSS property sets how background images are repeated. A background image can be repeated along the horizontal and vertical axes, or not repeated at all.
CSS Tutorial>Background> Background-repeat Thebackground-repeatproperty specifies whether a background image repeats itself, both horizontally and vertically. There are four possible values: repeat: the background image repeats both horizontally and vertically. This is the default value. ...
Default: repeat.Example HTML code 1:This example illustrates the use of the background-repeat property: .example { background-image: url("picture.gif"); background-repeat: repeat; width: 200px; height: 200px; } The background image, behind this element is repeated vertically an...