Get the App
SLTechnology News&Howtos  ›  Development  › 

How does css3 set the image to the border around the element

Shulou Source: shulou.com Published: 2022-06-01 06:51:23 11月13日 Update

This article mainly shows you "css3 how to set the image to the border around the element", the content is easy to understand, well-organized, hope to help you solve your doubts, the following let the editor lead you to study and learn "css3 how to set the image to the border around the element" this article.

That is, the image is specified as the border around the element.

The code is as follows:

# borderimg1 {

Width:600px

Border:15pxsolidtransparent

Padding:10px

-webkit-border-image:url ("/ test/img/19.png") 30round

Border-image:url ("/ test/img/19.png") 60round

}

# borderimg2 {

Width:600px

Border:15pxsolidtransparent

Padding:10px

-webkit-border-image:url ("/ test/img/19.png") 30stretch

}

The border-image border image attribute, which defines the picture as the border surrounding the div element:

Here the middle part of the image is repeated to create a boundary.

Here the middle part of the image is stretched to create a boundary.

The above is all the content of the article "how css3 sets the image to the border around the element". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!

Tags: Images borders elements content articles boundaries parts learning help that is code pictures attributes easy to understand more organization knowledge editing industry information Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno macOS MariaDB Docker Shulou Technology Apple