border: 10px solid transparent;
padding: 15px;
border-image: url(border-image.png) 30 round;
}
In this example, the middle part of the image is repeated to form a border.
Note : Internet Explorer 10 and earlier versions do not support the border-image attribute.
In this example, the middle part of the image is repeated to form a line
rim:
border-image: url (border-image.png) 30 round;
Original image:
Note: Internet Explorer 10 and older versions do not
Support border-image attribute.
Example 2: The middle part of the image is stretched to create a border.
#borderimg {
border: 10px solid transparent;
padding: 15px;
border-image: url(border-image.png) 30 stretch;
}
In this example, the middle part of the image is stretched to form a border.
In this example, the middle part of the image is stretched to form a line
rim:
border-image:
url (border-image.png) 30 stretch;
Original image:
Note: Internet Explorer 10 and older versions do not
Support border-image attribute.
The way to slice images to make different borders will create a lot of novelty, completely change the look of the border.
Type 1 slice:
#borderimg1 {
border: 10px solid transparent;
padding: 15px;
border-image: url(border-image.png) 50 round;
}
Type 2 slice:
#borderimg2 {
border: 10px solid transparent;
padding: 15px;
border-image: url(border-image.png) 20% round;
}
Type 3 slice:
#borderimg3 {
border: 10px solid transparent;
padding: 15px;
border-image: url(border-image.png) 30% round;
}
border-image: url (border-image.png) 50 round;
border-image: url (border-image.png) 20% round;
border-image: url (border-image.png) 30% round;
Note: Internet Explorer 10 and older versions do not
Support border-image attribute.