Positioning rectangle at the same height as text in header - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:Header

Description

Positioning rectangle at the same height as text in header

Demo Code

ResultView the demo in separate window

<html>
 <head> 
  <meta name="viewport" content="width=device-width, initial-scale=1"> 
  <style id="compiled-css" type="text/css">

header h1{<!--  w w w. j a v a  2  s. co  m-->
   vertical-align:middle;
   border-left:solid 5px red;
   padding:15px;
}


      </style> 
 </head> 
 <body> 
  <header> 
   <div id="rectangle"> 
   </div> 
   <div id="titulo"> 
    <h1>test test test test</h1> 
    <p>thi sis a test test test etst setse ts d sd s ts etset</p> 
   </div> 
  </header>  
 </body>
</html>

Related Tutorials