H2 with background color and underline - HTML CSS CSS Property

HTML CSS examples for CSS Property:background-color

Description

H2 with background color and underline

Demo Code

ResultView the demo in separate window


<html>
 <head> 
  <style>

h2{<!--from  w ww  .  ja v  a2 s. c  o  m-->
   border-bottom: 2px solid #000;
}
h2:first-line{
   background:#000;
   color:#fff;
}

      </style> 
 </head> 
 <body> 
  <h2>POPULAR NOW</h2>  
 </body>
</html>

Related Tutorials