Style borderImageRepeat Property
Example
Specify how to repeat the image-border:
document.getElementById("myDIV").style.borderImageRepeat = "round";
Try it yourself »
Definition and Usage
The borderImageRepeat property sets or returns whether the image-border should be repeated, rounded or stretched.
Browser Support
The borderImageRepeat property is not supported in Opera.
The borderImageRepeat property is not supported in Internet Explorer 10 and earlier.
The borderImageRepeat property is not supported in Safari 5 and earlier.
Look at the borderImage property instead!
Syntax
Return the borderImageRepeat property:
object.style.borderImageRepeat
Set the borderImageRepeat property:
object.style.borderImageRepeat="stretch|repeat|round|initial|inherit"
Property Values
Value | Description |
---|---|
stretch | Default value. The image is stretched to fill the area |
repeat | The image is tiled (repeated) to fill the area |
round | The image is tiled (repeated) to fill the area. If it does not fill the area with a whole number of tiles, the image is rescaled so it fits |
space | The image is tiled (repeated) to fill the area. If it does not fill the area with a whole number of tiles, the extra space is distributed around the tiles |
initial | Sets this property to its default value. Read about initial |
inherit | Inherits this property from its parent element. Read about inherit |
Technical Details
Default Value: | stretch |
---|---|
Return Value: | A String, representing the border-image-repeat property of an element |
CSS Version | CSS3 |
Related Pages
CSS reference: border-image-repeat property
Style Object