A free library of HTML, CSS, JS

Search This Blog

Monday, 28 November 2016

How To Create a border with Before & after css

<!DOCTYPE html>
.titlehome {font-size:24px;line-height:24px; text-align:center; padding:7px 15px 10px 15px; color:#000; font-weight:bold; margin-bottom:10px;position: relative;z-index: 1;}
.titlehome span { color: #000; text-align: center; background: #fff; padding: 0 50px;}
.titlehome:before {border-top: 2px solid #f67519;content: ""; margin: 0 auto; position: absolute; top: 50%; left: 0;right: 0;bottom: 0; width: 100%; z-index: -1;}

  <div class="titlehome"><span>Border  Design Css with Before & After Css</span></div>


No comments :

Post a Comment