border-image



значения свойства:


  • none
  • url()
  • number
  • %
  • thickness
  • stretch
  • repeat
  • round



css/style.css
  • * {
  •  margin: 0;
  •  padding: 0;
  • }
  •  
  • .a{
  •  height: 400px;
  •  width: 800px;
  •  position: absolute;
  •  top: 50%;
  •  left: 50%;
  •  margin-top: -230px;
  •  margin-left: -430px;
  •  border: 30px solid #D6E3BC;
  •  border-image: url(img/border.jpg) 30 stretch;
  • }
* {
 margin: 0;
 padding: 0;
}

.a{
 height: 400px;
 width: 800px;
 position: absolute;
 top: 50%;
 left: 50%;
 margin-top: -230px;
 margin-left: -430px;
 border: 30px solid #D6E3BC;
 border-image: url(img/border.jpg) 30 stretch;
}


index.html
  • <!DOCTYPE html>
  • <html>
  • <head>
  •  <meta charset="utf-8" />
  •  <title>New Page</title>
  •  <link href="css/style.css" rel="stylesheet" />
  • </head>
  • <body>
  •   <div class="a"></div>
  • </body>
  • </html>
  • <!DOCTYPE html>
  • <html>
  • <head>
  •  <meta charset="utf-8" />
  •  <title>New Page</title>
  •  <link href="css/style.css" rel="stylesheet" />
  • </head>
  • <body>
  •   <div class="a"></div>
  • </body>
  • </html>