HTML CSS examples for CSS Widget:Border Style
Create Border with inverted rectangular corners
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> div {<!--from www. ja v a2s . c o m--> width:80%; height: 200px; position: relative; margin:50px auto; background-color: #1c1c1c; } div:before, div:after { content:''; display: block; position: absolute; left: 10px; top:10px; right: 10px; bottom: 10px; } div:before { border-style: solid; border-width: 16px; -moz-border-image: url('https://www.java2s.com/style/demo/Firefox.png') 16 repeat; -webkit-border-image: url('https://www.java2s.com/style/demo/InternetExplorer.png') 16 repeat; -o-border-image: url('https://www.java2s.com/style/demo/InternetExplorer.png') 16 repeat; border-image: url('https://www.java2s.com/style/demo/Safari.png') 16 repeat; } div:after { border:2px solid #FFF; left:14px; top:14px; right:14px; bottom:14px; } </style> </head> <body> <div></div> </body> </html>