YouTip LogoYouTip

Prop Style Borderimageslice

# HTML DOM Style borderImageSlice Property [![Image 8: Style Object Reference](#) Style Object](#) ## Example Specifies the inward offset of the border image: document.getElementById("myDIV").style.borderImageSlice="50% 10%"; [Try it Yourself Β»](#) * * * ## Definition and Usage The `borderImageSlice` property specifies the inward offset of the border image. * * * ## Browser Support ![Image 9: Internet Explorer](#)![Image 10: Firefox](#)![Image 11: Opera](#)![Image 12: Google Chrome](#)![Image 13: Safari](#) Opera does not support the `borderImageSlice` property. Internet Explorer 10 and earlier versions do not support the `borderImageSlice` property. Safari 5 and earlier versions do not support the `borderImageSlice` property. See the (#) property as an alternative! * * * ## Syntax Get the `borderImageSlice` property: _object_.style.borderImageSlice Set the `borderImageSlice` property: _object_.style.borderImageSlice="_number_|_%_|fill|initial|inherit" ## Property Values | Value | Description | | --- | --- | | _number_ | A number representing the image pixels (if the image is a raster image) or vector coordinates (if the image is a vector image). | | _%_ | A percentage representing the offset relative to the size of the image: the horizontal offset refers to the width of the image, and the vertical offset refers to the height of the image. The default value is 100%. | | fill | Preserves the middle part of the border image. | | initial | Sets this property to its default value. See (#). | | inherit | Inherits this property from its parent element. See (#). | ## Technical Details | Default Value: | 100% | | --- | | Return Value: | A string, representing the border-image-slice property of the element. | | CSS Version | CSS3 | * * * ## Related Articles CSS Reference: (#) * * Style Object](#)
← Prop Style BorderimagesourceProp Style Borderimagerepeat β†’